Yeoman Express Stack is fork Yeoman ( comment perev .: article on Habré ). The fork was created to prove the ability to develop a full stack (client-server) using Yeoman 0.9.6, Express and AngularJS. Note: this is an experimental branch and (for now) is only suitable for testing and running in the concept. Includes:
Specialized version of Yeoman server.js with support for Express-Middleware
Out of the box is supported LiveReload
Generator for Express and CRUD — generator for AngularJS
It is assumed that you will locate the code and the client and server parts of the application in the same directory. After installation, you can see the structure of the built-in test application: the server directory for the server side of the application and the app directory for the client side.
Components
yeoman-custom - Yeoman 0.9.6 Special Edition with Express Middle Support
generators - generators for Express and AngularJS (CRUD)
demo - example application
')
Installation (assuming Yeoman@0.9.6 is already installed)
Clone repository
git clone git://github.com/yeoman/yeoman.git cd yeoman git checkout express-stack
Now you have a new yeomen team (noticed e instead of a in yeoman ? - e means express ); This command can run a separate copy of yeoman to use the new generators listed below.
Let's start
After the installation process is completed, you have two options - you can start a new application using the commands listed below, or go to the demo, which already has a small sample code so that you can try the finished project.
yeomen init angularcrud # Angular yeomen init angularcrud:crud post # Angular CRUD routes/views yeomen init express post # Express CRUD yeomen server # #/api/post/index # Express
Note: If there are errors that Express is not installed, run npm install express .
Demo
Now you can go to the demo directory and run the yeomen server command to start this application. If you have several versions of yeoman locally installed, you can use yeoman-custom directly, but in general it should work this way.
And finally the generators. The following are supported:
Notetrans. You can put together an opinion about how convenient Yeoman is to develop applications on AngularJS by video (video is long but interesting; the process of creating a simple store is shown): ( watch from 13:40 ) http://youtu.be/XOmwZopzcTA?t=13m40s . In any case, I emphasize that the video uses the usual Yeoman assembly, and only the client part is developed.