0.4.2 • Published 9 years ago

generator-marionette-modules v0.4.2

Weekly downloads
5
License
MIT
Repository
github
Last release
9 years ago

generator-marionette-modules Build Status

Yeoman generator. For scaffolding a Marionette app with the Module pattern.

This project uses things like: less, dustjs (linkedin), requirejs and mocha.

Getting Started

First make sure you have Yeoman installed:

$ npm install -g yo

Then install generator-marionette-modules from npm, run:

$ npm install -g generator-marionette-modules

Make a new directory, and cd into it:

$ mkdir newProject && cd $_

Then initiate the generator, optionally passing an app name:

$ yo marionette-modules [appName]

Then start generating modules for your app like so:

$ yo marionette-modules:module [MODULENAME]

To generate action (submodules) for your app:

NOTE: there are no args or options at this point for action

$ yo marionette-modules:action

NOTE: This is not complete:

If you want just a view for a module use: (Eg: list, show etc.)

$ yo marionette-modules:view [MODULENAME] [VIEWNAME]

How to setup.

After you install a module, you also need to configure it to run.

So in your main app.js file, change the placeholder MODULENAME to whatever you named your module, in the two places listed below

To load your module change line 59:

require(['modules/MODULENAME/app'], function () {

Also on line 70, change the home page to one of your choosing:

App.trigger('MODULENAME:list');

For dev:

grunt watch

To build for prod:

grunt build

To run tests:

grunt test

License

MIT

0.4.2

9 years ago

0.4.1

9 years ago

0.3.0

10 years ago

0.2.10

10 years ago

0.2.9

10 years ago

0.2.8

10 years ago

0.2.7

10 years ago

0.2.6

10 years ago

0.2.2

10 years ago

0.2.1

10 years ago