Skip to content

cgross/ng-parse-module

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ng-parse-module Build Status

Small utility to read/write Angular module creation calls.

Example

var ngParseModule = require('ng-parse-module');

//read module from file
var results = ngParseModule('app.js');

//update module dependencies and rewrite
results.dependencies.modules.push('newDependency');
results.save();

API

ngParseModule(file)

Parses the file and returns an object the following properties:

  • file - Name of the file parsed.
  • name - Name of the Angular module.
  • dependencies - Object containing start, end, and modules properties.
  • contents - Contents of the file parsed.
  • save - Function that will rewrite the parsed file with any changes the dependencies.modules property reflected in the new source.

About

Small utility to read/write Angular module creation calls.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published