skypager-document
the document asset wrapper for skypager projects
Last updated 3 years ago by soederpop .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install skypager-document 
SYNC missed versions from official npm registry.

Skypager Document Collections

Document Collections are a tool for turning the files inside of your project folder into collections of abstract objects, or entities, and working with them as if they were rows in relational database, or active record objects in an ORM.

It is assumed that the project folder is composed of different subfolders and that generally these subfolders have a specific purpose. This library makes it easy to combine the logic of the project's file organization with information gathered from naming conventions (which are usually prescribed by a framework anyway) with more advanced metadata that can be extracted from parsing the actual files, building an AST, or more advanced tools if the language supports introspection.

Installation

npm install skypager-document --save

Usage

import { mountCollection } from 'skypager-document'

const project = mountCollection(cwd, {
  type: 'project',
  sync: true
})

project.scope('components', /components\/.*\/index.js$/)

// list all of the components
project.scopes.components # [file1, file2, etc]

Examples

ES6 Document Collections

Parses javascript files with babel's es6 parser, as well as the esdoc parser, and makes information extracted from these ASTs available for the purposes of building metadata structures about the code.

Used to auto generate documentation and test suites.

Markdown Collections

Renders markdown documents into HTML but not before extracting information from the writing a which can be used to programatically generate additional content, either by using the writing to fetch external data from some other API or database.

React Component Registry

TODO

Redux Component Registry

TODO

Current Tags

  • 4.3.1                                ...           latest (3 years ago)

9 Versions

  • 4.3.1                                ...           3 years ago
  • 4.3.0                                ...           3 years ago
  • 4.2.3                                ...           3 years ago
  • 4.2.1                                ...           3 years ago
  • 4.2.0                                ...           3 years ago
  • 4.0.3                                ...           3 years ago
  • 4.0.2                                ...           3 years ago
  • 4.0.1                                ...           3 years ago
  • 4.0.0                                ...           3 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 1
Last Day 0
Last Week 1
Last Month 6
Dependencies (10)
Dev Dependencies (7)
Dependents (1)

Copyright 2014 - 2017 © taobao.org |