diogoazevedos / x-ray-build

A helper that build a x-ray based on a schema

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

x-ray-build

Build Status Coverage Status

A helper that build a x-ray based on a schema.

Getting started

npm install x-ray-build
const x = require('x-ray');
const build = require('x-ray-build');

const drive = x();
const crawl = build(drive, {
  $source: 'https://github.com/diogoazevedos',
  $context: '[itemscope]',
  $selector: {
    name: '.vcard-fullname',
    repos: {
      $context: '.source',
      $selector: [{
        name: '.repo',
      }],
    },
  },
});

crawl((e, content) => console.log(content));

About

A helper that build a x-ray based on a schema

License:MIT License


Languages

Language:JavaScript 100.0%