An open API service indexing awesome lists of open source software.

https://github.com/camargo/ng-seed

Simple Angular seed project with commonly used features.
https://github.com/camargo/ng-seed

angular angular-2 angular2 aot material ng-seed ng2 seed starter

Last synced: 5 months ago
JSON representation

Simple Angular seed project with commonly used features.

Awesome Lists containing this project

README

          

# ng-seed
***Note: This project was made when the [Angular CLI](https://cli.angular.io/) 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](https://palantir.github.io/tslint/) & [Codelyzer](https://github.com/mgechev/codelyzer))
4. Unit Testing ([Karma](https://karma-runner.github.io/) & [Jasmine](https://jasmine.github.io/))
5. E2E Testing ([Protractor](http://www.protractortest.org/))
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

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

## Remove Dependencies & Built Folders

```bash
rm -rf node_modules
rm -rf dist
```

## Run via Webpack (Dev Mode)

```bash
npm run build:dev
```

Visit [http://localhost:8080/](http://localhost:8080/) to view the running application.

## Run via Docker (Prod Mode)

Build image and run container from that image:

```bash
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:

```bash
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/](http://localhost:8081/) to view the running application.

## Run Linting

```bash
npm run lint
```

## Run Unit Tests

```bash
npm run unit
```

## Run E2E Tests

```bash
npm run e2e
```