Nuclear Powered Marshmallows

gobble-amdclean

0.1.0 • Public • Published

gobble-amdclean

Convert AMD code to standard JavaScript with gobble and AMDClean.

Installation

First, you need to have gobble installed - see the gobble readme for details. Then,

npm i -D gobble-amdclean

Usage

gobblefile.js

var gobble = require( 'gobble' );
module.exports = gobble( 'requirejs-output' ).map( 'amdclean', amdCleanOptions );

The AMDClean options are as per the documentation (the code property will be overwritten by gobble).

Source code

module.exports = amdclean;
 
function amdclean ( code, options ) {
  options.code = code;
  return require( 'amdclean' ).clean( options );
}
 
amdclean.defaults = {
  accept: '.js'
};

License

MIT. Copyright 2014 Rich Harris

Keywords

install

npm i gobble-amdclean

Downloadsweekly downloads

1

version

0.1.0

license

none

last publish

collaborators

  • avatar
Report a vulnerability