grunt-amd-namer
Name anonymous AMD modules using AST parsing
Common Usage
This task is useful if you're using an AMD loader that requires modules to have explicit names (e.g. almond). This is especially useful if you're handling bundling yourself, as opposed to using r.js.
Output Example
input
my-file.js
;
output
my-file.js
;
Getting Started
This plugin requires Grunt.
If you haven't used Grunt before, be sure to check out the Getting Started guide, as it explains how to create a Gruntfile as well as install and use Grunt plugins. Once you're familiar with that process, you may install this plugin with this command:
npm install grunt-amd-namer --save-dev
Once the plugin has been installed, it may be enabled inside your Gruntfile with this line of JavaScript:
grunt;
The "amd_namer" Task
grunt
Contributing
Feel free to open issues and send pull-requests.
Release History
- 2015-09-07 v1.0.0 Must pass
baseUrl
option
License
Copyright (c) 2015 cowchimp. Licensed under the MIT license.