4 | Note that this is only a getting started guide, for more detailed information about the build system, the available tasks, the configuration of the build or anything else, please refer to the documentation on the GitHub project. 5 |
6 | 7 |
9 | angular-kickstart
is an opinionated kickstart for single page application development with AngularJS. It makes your development and testing easy, keeps the structure of the project consistent and allows you to create a fully optimized
10 | production release withe ease. After having developed a lot of AngularJS projects I decided to collect here what I've learnt.
11 |
15 | Install 16 | node.js. Then 17 | sass, gulp and bower if you haven't yet. 18 |
19 | 20 |
21 |
22 | $ gem install sass
23 | $ npm -g install gulp bower
24 |
25 |
26 |
27 |
28 | After that, install
29 | angular-kickstart
- download the latest release (or clone the master branch if want to run the development version). Unzip the project and cd into it, then
30 | install bower and npm dependencies, and run the application in development mode.
31 |
34 |
35 | $ npm install
36 | $ bower install
37 | $ gulp serve
38 |
39 |
40 |
41 |
42 | You are now ready to go, your applcation is available at http://127.0.0.1:3000
.
43 |
45 | You are now ready to start coding, every file you add, edit or delete into the
46 | /client
folder, will be handled by the build system and the browser will reload.
47 |
49 | When you are ready to build a production release there is a task for that. 50 |
51 | 52 |
53 |
54 | $ gulp serve:dist
55 |
56 |
57 |
58 |
59 | This task will lint your code, optimize css js and images files, run unit tests. After the task has successfully finished, you can find an optimized version of your project in the
60 | /build/dist
folder.
61 |
64 | Other tasks are available: 65 |
66 | 67 |
68 |
69 | #for developing running unit test on every file change.
70 | $ gulp serve:tdd
71 |
72 | #for running e2e test. (you application should be running on http://127.0.0.1:3000)
73 | $ gulp test:e2e
74 |
75 | #for running unit tests one time then exit.
76 | $ gulp test:unit
77 |
78 |
79 | 80 | 81 | Full documentation on GitHub 82 | 83 |
84 | 85 |angular-kickstart
will take care of the rest.The best JavaScript framework out there will power up your awesome app. 37 |
38 |A smart and scalable gulpjs based build system will take care of your development and testing workflow, as well as the optimization process for production release. Read more... 46 |
47 |Sass is the most mature, stable, and powerful professional grade CSS extension language. The project is structured following the SMACSS architecture.
63 | Write your CSS in a modular and scalable way, the build system will compile your .scss
files into a single css files. It should be easy to integrate less, stylus or any other preprocessor if you prefer. Pure is the default CSS framework, by you can easily plug your own.
angular-kickstart comes with a
69 | by-feature
files organization, keeping your code organized, especially if you are working on a large code-base. If you don't like it, just use your preferred structure, and the build system will still work. The code is written following best practices that make you able to write consistent code. Read more...
70 |
Every general purpose directive, service or filter, should be placed into the common
directory, in this way you can copy and paste the directory into another project, require the module you need, and you are ready to go with your new project.
76 |
The build system comes with a special task for running tests by using Karma Test Runner. 84 |
85 |end-to-end testing support is provided by the build system. Tests can be executed using protractor.
90 |Easily optimize css js and images files for production.
95 |© 2014 - Alessandro Arnodo. 4 |