camargo / ng-seed

Simple Angular seed project with commonly used features.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

ng-seed

Note: This project was made when the Angular CLI was immature. I now recommend using the CLI for starting new Angular projects.

This is a basic application that you can use to bootstrap your new Angular project. To get started, change all occurrences of "app" in this project to your app name.

Features

  1. Angular 5.1.0 (2017-12-06)
  2. Webpack 3
  3. Linting (TSLint & Codelyzer)
  4. Unit Testing (Karma & Jasmine)
  5. E2E Testing (Protractor)
  6. Docker
  7. Routing
    • /home: Not lazy-loaded
    • /about: Lazy-loaded
  8. HTTP Request via Service (GET public IP address)
  9. Dev build (via Webpack Dev Server), and Prod build (via AOT)

Download Project & Install Dependencies

git clone https://github.com/camargo/ng-seed.git
cd ng-seed
npm cache clean
npm install

Remove Dependencies & Built Folders

rm -rf node_modules
rm -rf dist

Run via Webpack (Dev Mode)

npm run build:dev

Visit http://localhost:8080/ to view the running application.

Run via Docker (Prod Mode)

Build image and run container from that image:

npm run build:prod
docker build -t app-image $(pwd)/dist
docker run --name app -d -p 8081:80 app-image

Or just run container:

npm run build:prod
docker run --name app -v $(pwd)/dist:/usr/share/nginx/html:ro -d -p 8081:80 nginx

Visit http://localhost:8081/ to view the running application.

Run Linting

npm run lint

Run Unit Tests

npm run unit

Run E2E Tests

npm run e2e

About

Simple Angular seed project with commonly used features.


Languages

Language:TypeScript 51.4%Language:JavaScript 43.0%Language:HTML 5.1%Language:CSS 0.4%