MinionsDave / ISA

management webapp of isa.qa company

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

ISA management webapp

this project was generated by generator-gulp-angular

you need

  1. nodejs
  2. mongodb

after clone the project you need run

  1. npm install
  2. bower install

Usage

Yo options

yo gulp-angular --help or yo gulp-angular -h for help. All options are not required. If not provided, default values will be used.

  • --app-path='src' customize Angular's app folder, relative to cwd, default is src
  • --dist-path='dist' customize build target folder, relative to cwd, default is dist
  • --e2e-path='e2e' customize e2e test specs folder, relative to cwd, default is e2e
  • --tmp-path='.tmp' customize pre-processing temp folder, relative to cwd, default is .tmp
  • --skip-install do not run bower install and npm install after generating the app, default is false (not skip)
  • --skip-welcome-message skip yo welcome messages, default is false (not skip)
  • --skip-message skip install messages, default is false (not skip)
  • --default use default configurations, default is false
  • --advanced prompt for advanced additional features, default is false

Paths configuration are stored in gulpfile.js. Change options.(src|dist|tmp|e2e) in gulpfile.js if you want to config paths after the app is generated.

Warning: The paths are also written in the index.html for the build with useref. If you want to change these paths, you also have to change the paths there in order to have the build task working.

Use Gulp tasks

  • gulp or gulp build to build an optimized version of your application in /dist
  • gulp serve to launch a browser sync server on your source files
  • gulp serve:dist to launch a server on your optimized application
  • gulp test to launch your unit tests with Karma
  • gulp test:auto to launch your unit tests with Karma in watch mode
  • gulp protractor to launch your e2e tests with Protractor
  • gulp protractor:dist to launch your e2e tests with Protractor on the dist files

Directory structure

Best Practice Recommendations for Angular App Structure

The root directory generated with default paths configuration for application with name gulpAngular:

├──  bower_components/
├──  e2e/
├──  gulp/
├──  nodes_modules/
│
├──  src/
│   ├──  app/
│   │   ├──  components/
│   │   │   └──  githubContributor/
│   │   │   │   └──  githubContributor.service.js
│   │   │   │
│   │   │   └──  malarkey/
│   │   │   │   ├──  malarkey.directive.js
│   │   │   │   └──  malarkey.(scss|styl|less|css)
│   │   │   │
│   │   │   └──  navbar/
│   │   │   │   ├──  navbar.directive.(js|ts|coffee)
│   │   │   │   ├──  navbar.html
│   │   │   │   └──  navbar.(scss|styl|less|css)
│   │   │   │
│   │   │   └──  webDevTec/
│   │   │       └──  webDevTec.service.js
│   │   │
│   │   ├──  main/
│   │   │   ├──  main.controller.(js|ts|coffee)
│   │   │   ├──  main.controller.spec.js
│   │   │   └──  main.html
│   │   │
│   │   └──  index.config.(js|ts|coffee)
│   │   └──  index.constants.(js|ts|coffee)
│   │   └──  index.module.(js|ts|coffee)
│   │   └──  index.route.(js|ts|coffee)
│   │   └──  index.run.(js|ts|coffee)
│   │   └──  index.(scss|styl|less|css)
|   |
│   ├──  assets/
│   │   └──  images/
│   ├──  favico.ico
│   └──  index.html
│
├──  .bowerrc
├──  .editorconfig
├──  .gitignore
├──  .eslintrc
├──  bower.json
├──  gulpfile.js
├──  karma.conf.js
├──  package.json
└──  protractor.conf.js

There is none at the generation but you can add .jade, .haml or .hbs (dependent of your HTML pre-processor choice) anywhere in the src folder and it will be compiled automatically. Warning, the first file of a type in a folder is often missed by the Gulp watch, try to relaunch Gulp if it happens.

Features included in the gulpfile

  • useref : allow configuration of your files in comments of your HTML file
  • ngAnnotate : convert simple injection to complete syntax to be minification proof
  • uglify : optimize all your JavaScript
  • csso : optimize all your CSS
  • autoprefixer : add vendor prefixes to CSS
  • rev : add a hash in the file names to prevent browser cache problems
  • watch : watch your source files and recompile them automatically
  • eslint : The pluggable linting utility for JavaScript
  • imagemin : all your images will be optimized at build
  • Unit test (karma) : out of the box unit test configuration with karma
  • e2e test (protractor) : out of the box e2e test configuration with protractor
  • browser sync : full-featured development web server with livereload and devices sync
  • angular-templatecache : all HTML partials will be converted to JS to be bundled in the application
  • TODO lazy : don't process files which haven't changed when possible

About

management webapp of isa.qa company


Languages

Language:JavaScript 78.0%Language:HTML 16.5%Language:CSS 4.1%Language:Shell 1.3%