https://github.com/anistark/neptune
Angular+Webpack Boilerplate
https://github.com/anistark/neptune
angular angular2 angularjs neptune typedoc webpack
Last synced: about 2 months ago
JSON representation
Angular+Webpack Boilerplate
- Host: GitHub
- URL: https://github.com/anistark/neptune
- Owner: anistark
- License: mit
- Created: 2017-08-26T14:06:40.000Z (almost 9 years ago)
- Default Branch: master
- Last Pushed: 2017-09-29T04:53:10.000Z (over 8 years ago)
- Last Synced: 2026-03-29T21:08:03.900Z (3 months ago)
- Topics: angular, angular2, angularjs, neptune, typedoc, webpack
- Language: JavaScript
- Homepage: https://anistark.github.io/neptune
- Size: 1.92 MB
- Stars: 1
- Watchers: 2
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# [Neptune][documentationLink]
### install the dependencies with npm
$ npm install
### start the server
$ npm start
```
[http://localhost:8080](http://localhost:8080)
```
As an alternative, you can work using Hot Module Replacement (HMR):
* `npm run start:hmr`
And you are all set! You can now modify your components on the fly without having to reload the entire page.
## Testing
#### 1. Unit Tests
* single run: `npm test`
* live mode (TDD style): `npm run test-watch`
#### 2. End-to-End Tests (aka. e2e, integration)
* single run:
* in a tab, *if not already running!*: `npm start`
* in a new tab: `npm run webdriver-start`
* in another new tab: `npm run e2e`
* interactive mode:
* instead of the last command above, you can run: `npm run e2e-live`
* when debugging or first writing test suites, you may find it helpful to try out Protractor commands without starting up the entire test suite. You can do this with the element explorer.
* you can learn more about [Protractor Interactive Mode here](https://github.com/angular/protractor/blob/master/docs/debugging.md#testing-out-protractor-interactively)
## Production
To build your application, run:
* `npm run build`
You can now go to `/dist` and deploy that to your server!
Push the dist folder to gh-pages branch:
* `git subtree push --prefix dist origin gh-pages`
## Documentation
You can generate api docs (using [TypeDoc](http://typedoc.org/)) for your code with the following:
* `npm run docs`
#### How to include external angular libraries ?
It's simple, just install the lib via npm and import it in your code when you need it. Don't forget that you need to configure some external libs in the [bootstrap](https://github.com/preboot/angular-webpack/blob/master/src/main.ts) of your application.
#### How to include external css files such as bootstrap.css ?
Just install the lib and import the css files in [vendor.ts](https://github.com/preboot/angular-webpack/blob/master/src/vendor.ts). For example this is how to do it with bootstrap:
```sh
npm install bootstrap@next --save
```
And in [vendor.ts](https://github.com/preboot/angular-webpack/blob/master/src/vendor.ts) add the following:
```ts
import 'bootstrap/dist/css/bootstrap.css';
```
Sources :
- https://github.com/preboot/angular-webpack
# License
[MIT](/LICENSE)
[documentationLink]: https://anistark.github.io/neptune