Skip to content

Commit 14abef9

Browse files
committed
feat: project skeleton
1 parent 65449f9 commit 14abef9

31 files changed

+87
-54
lines changed

.angular-cli.json

100755100644
+2-2
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
"testTsconfig": "tsconfig.spec.json",
2020
"prefix": "app",
2121
"styles": [
22-
"styles.css"
22+
"styles.scss"
2323
],
2424
"scripts": [],
2525
"environmentSource": "environments/environment.ts",
@@ -51,7 +51,7 @@
5151
}
5252
},
5353
"defaults": {
54-
"styleExt": "css",
54+
"styleExt": "scss",
5555
"component": {}
5656
}
5757
}

.editorconfig

100755100644
File mode changed.

.gitignore

100755100644
File mode changed.

.travis-deploy.sh

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
#!/usr/bin/env bash
2+
# go to the directory which contains build artifacts and create a *new* Git repo
3+
# directory may be different based on your particular build process
4+
cd dist
5+
git init
6+
7+
# inside this git repo we'll pretend to be a new user
8+
git config user.name "Travis CI"
9+
git config user.email "[email protected]"
10+
11+
# The first and only commit to this new Git repo contains all the
12+
# files present with the commit message "Deploy to GitHub Pages".
13+
git add .
14+
git commit -m "Deploy to GitHub Pages"
15+
16+
# Force push from the current repo's master branch to the remote
17+
# repo's gh-pages branch. (All previous history on the gh-pages branch
18+
# will be lost, since we are overwriting it.) We redirect any output to
19+
# /dev/null to hide any sensitive credential data that might otherwise be exposed.
20+
# tokens GH_TOKEN and GH_REF will be provided as Travis CI environment variables
21+
git push --force --quiet "https://${GH_TOKEN}@${GH_REF}" master:gh-pages > /dev/null 2>&1

.travis.yml

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
language: node_js
2+
node_js:
3+
- "6"
4+
script:
5+
# run build script specified in package.json
6+
- npm run ci
7+
# call script for deploying of produced artifacts
8+
- bash ./.travis-deploy.sh

README.md

100755100644
+4-27
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,5 @@
1-
# AngularNgrxMaterialStarter
1+
# Angular, ngrx & Material Starter by [@tomastrajan](https://twitter.com/tomastrajan) [![Build Status](https://travis-ci.org/tomastrajan/angular-ngrx-material-starter.svg?branch=master)](https://travis-ci.org/tomastrajan/angular-ngrx-material-starter)
2+
3+
Check out [Demo & Documentation](http://tomastrajan.github.io/angular-ngrx-material-starter/)
24

3-
This project was generated with [Angular CLI](https://github.com/angular/angular-cli) version 1.0.3.
4-
5-
## Development server
6-
7-
Run `ng serve` for a dev server. Navigate to `http://localhost:4200/`. The app will automatically reload if you change any of the source files.
8-
9-
## Code scaffolding
10-
11-
Run `ng generate component component-name` to generate a new component. You can also use `ng generate directive|pipe|service|class|module`.
12-
13-
## Build
14-
15-
Run `ng build` to build the project. The build artifacts will be stored in the `dist/` directory. Use the `-prod` flag for a production build.
16-
17-
## Running unit tests
18-
19-
Run `ng test` to execute the unit tests via [Karma](https://karma-runner.github.io).
20-
21-
## Running end-to-end tests
22-
23-
Run `ng e2e` to execute the end-to-end tests via [Protractor](http://www.protractortest.org/).
24-
Before running the tests make sure you are serving the app via `ng serve`.
25-
26-
## Further help
27-
28-
To get more help on the Angular CLI use `ng help` or go check out the [Angular CLI README](https://github.com/angular/angular-cli/blob/master/README.md).
5+
Built with [Angular CLI](https://github.com/angular/angular-cli)

e2e/app.e2e-spec.ts

100755100644
File mode changed.

e2e/app.po.ts

100755100644
File mode changed.

e2e/tsconfig.e2e.json

100755100644
File mode changed.

karma.conf.js

100755100644
+2
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@ module.exports = function (config) {
88
plugins: [
99
require('karma-jasmine'),
1010
require('karma-chrome-launcher'),
11+
require('karma-phantomjs-launcher'),
12+
require('karma-spec-reporter'),
1113
require('karma-jasmine-html-reporter'),
1214
require('karma-coverage-istanbul-reporter'),
1315
require('@angular/cli/plugins/karma')

package.json

100755100644
+18-3
Original file line numberDiff line numberDiff line change
@@ -8,20 +8,33 @@
88
"build": "ng build",
99
"test": "ng test",
1010
"lint": "ng lint",
11-
"e2e": "ng e2e"
11+
"e2e": "ng e2e",
12+
"watch": "ng test --browsers PhantomJS --reporters spec",
13+
"build:prod": "ng build --target production --aot --vendor-chunk --extract-css --output-hashing all --stats-json",
14+
"build:travisci": "ng build --target production --aot --vendor-chunk --extract-css --output-hashing all --stats-json --deploy-url /angular-ngrx-material-starter/ --base-href /angular-ngrx-material-starter",
15+
"clean": "rm -rf ./dist/",
16+
"server": "cd dist && http-server",
17+
"prod": "npm run clean && npm run build:prod && npm run server",
18+
"ci": "npm run clean && ng lint && ng test --browsers PhantomJS --single-run --reporters spec && npm run build:travisci"
1219
},
1320
"private": true,
1421
"dependencies": {
22+
"@angular/animations": "^4.1.1",
1523
"@angular/common": "^4.0.0",
1624
"@angular/compiler": "^4.0.0",
1725
"@angular/core": "^4.0.0",
1826
"@angular/forms": "^4.0.0",
1927
"@angular/http": "^4.0.0",
28+
"@angular/material": "^2.0.0-beta.3",
2029
"@angular/platform-browser": "^4.0.0",
2130
"@angular/platform-browser-dynamic": "^4.0.0",
2231
"@angular/router": "^4.0.0",
32+
"classlist.js": "^1.1.20150312",
2333
"core-js": "^2.4.1",
34+
"hammerjs": "^2.0.8",
35+
"intl": "^1.2.5",
2436
"rxjs": "^5.1.0",
37+
"web-animations-js": "^2.2.5",
2538
"zone.js": "^0.8.4"
2639
},
2740
"devDependencies": {
@@ -33,11 +46,13 @@
3346
"jasmine-core": "~2.5.2",
3447
"jasmine-spec-reporter": "~3.2.0",
3548
"karma": "~1.4.1",
36-
"karma-chrome-launcher": "~2.1.1",
49+
"karma-chrome-launcher": "~2.0.0",
3750
"karma-cli": "~1.0.1",
51+
"karma-coverage-istanbul-reporter": "^0.2.0",
3852
"karma-jasmine": "~1.1.0",
3953
"karma-jasmine-html-reporter": "^0.2.2",
40-
"karma-coverage-istanbul-reporter": "^0.2.0",
54+
"karma-phantomjs-launcher": "^1.0.4",
55+
"karma-spec-reporter": "0.0.31",
4156
"protractor": "~5.1.0",
4257
"ts-node": "~2.0.0",
4358
"tslint": "~4.5.0",

protractor.conf.js

100755100644
File mode changed.

src/app/app.component.html

100755100644
+2
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
11
<h1>
22
{{title}}
3+
4+
<button md-raised-button>Raised button</button>
35
</h1>
File renamed without changes.

src/app/app.component.spec.ts

100755100644
File mode changed.

src/app/app.component.ts

100755100644
+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import { Component } from '@angular/core';
33
@Component({
44
selector: 'app-root',
55
templateUrl: './app.component.html',
6-
styleUrls: ['./app.component.css']
6+
styleUrls: ['./app.component.scss']
77
})
88
export class AppComponent {
99
title = 'app works!';

src/app/app.module.ts

100755100644
+10-4
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,24 @@
1+
import 'hammerjs';
12
import { BrowserModule } from '@angular/platform-browser';
23
import { NgModule } from '@angular/core';
34
import { FormsModule } from '@angular/forms';
45
import { HttpModule } from '@angular/http';
6+
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
7+
import { MdButtonModule } from '@angular/material';
8+
59

610
import { AppComponent } from './app.component';
711

812
@NgModule({
9-
declarations: [
10-
AppComponent
11-
],
1213
imports: [
1314
BrowserModule,
1415
FormsModule,
15-
HttpModule
16+
HttpModule,
17+
BrowserAnimationsModule,
18+
MdButtonModule
19+
],
20+
declarations: [
21+
AppComponent
1622
],
1723
providers: [],
1824
bootstrap: [AppComponent]

src/assets/.gitkeep

100755100644
File mode changed.

src/environments/environment.prod.ts

100755100644
File mode changed.

src/environments/environment.ts

100755100644
File mode changed.

src/favicon.ico

100755100644
File mode changed.

src/index.html

100755100644
+1
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77

88
<meta name="viewport" content="width=device-width, initial-scale=1">
99
<link rel="icon" type="image/x-icon" href="favicon.ico">
10+
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
1011
</head>
1112
<body>
1213
<app-root>Loading...</app-root>

src/main.ts

100755100644
File mode changed.

src/polyfills.ts

100755100644
+17-17
Original file line numberDiff line numberDiff line change
@@ -19,22 +19,22 @@
1919
*/
2020

2121
/** IE9, IE10 and IE11 requires all of the following polyfills. **/
22-
// import 'core-js/es6/symbol';
23-
// import 'core-js/es6/object';
24-
// import 'core-js/es6/function';
25-
// import 'core-js/es6/parse-int';
26-
// import 'core-js/es6/parse-float';
27-
// import 'core-js/es6/number';
28-
// import 'core-js/es6/math';
29-
// import 'core-js/es6/string';
30-
// import 'core-js/es6/date';
31-
// import 'core-js/es6/array';
32-
// import 'core-js/es6/regexp';
33-
// import 'core-js/es6/map';
34-
// import 'core-js/es6/set';
22+
import 'core-js/es6/symbol';
23+
import 'core-js/es6/object';
24+
import 'core-js/es6/function';
25+
import 'core-js/es6/parse-int';
26+
import 'core-js/es6/parse-float';
27+
import 'core-js/es6/number';
28+
import 'core-js/es6/math';
29+
import 'core-js/es6/string';
30+
import 'core-js/es6/date';
31+
import 'core-js/es6/array';
32+
import 'core-js/es6/regexp';
33+
import 'core-js/es6/map';
34+
import 'core-js/es6/set';
3535

3636
/** IE10 and IE11 requires the following for NgClass support on SVG elements */
37-
// import 'classlist.js'; // Run `npm install --save classlist.js`.
37+
import 'classlist.js'; // Run `npm install --save classlist.js`.
3838

3939
/** IE10 and IE11 requires the following to support `@angular/animation`. */
4040
// import 'web-animations-js'; // Run `npm install --save web-animations-js`.
@@ -46,7 +46,7 @@ import 'core-js/es7/reflect';
4646

4747

4848
/** ALL Firefox browsers require the following to support `@angular/animation`. **/
49-
// import 'web-animations-js'; // Run `npm install --save web-animations-js`.
49+
import 'web-animations-js'; // Run `npm install --save web-animations-js`.
5050

5151

5252

@@ -65,8 +65,8 @@ import 'zone.js/dist/zone'; // Included with Angular CLI.
6565
* Date, currency, decimal and percent pipes.
6666
* Needed for: All but Chrome, Firefox, Edge, IE11 and Safari 10
6767
*/
68-
// import 'intl'; // Run `npm install --save intl`.
68+
import 'intl'; // Run `npm install --save intl`.
6969
/**
7070
* Need to import at least one locale-data with intl.
7171
*/
72-
// import 'intl/locale-data/jsonp/en';
72+
import 'intl/locale-data/jsonp/en';
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
11
/* You can add global styles to this file, and also import other style files */
2+
@import '~@angular/material/prebuilt-themes/deeppurple-amber.css';

src/test.ts

100755100644
File mode changed.

src/tsconfig.app.json

100755100644
File mode changed.

src/tsconfig.spec.json

100755100644
File mode changed.

src/typings.d.ts

100755100644
File mode changed.

tsconfig.json

100755100644
File mode changed.

tslint.json

100755100644
File mode changed.

0 commit comments

Comments
 (0)