Skip to content

Commit

Permalink
feat: project skeleton
Browse files Browse the repository at this point in the history
  • Loading branch information
tomastrajan committed May 10, 2017
1 parent e5746e6 commit 3ea3e3f
Show file tree
Hide file tree
Showing 31 changed files with 87 additions and 54 deletions.
4 changes: 2 additions & 2 deletions .angular-cli.json
100755 → 100644
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"testTsconfig": "tsconfig.spec.json",
"prefix": "app",
"styles": [
"styles.css"
"styles.scss"
],
"scripts": [],
"environmentSource": "environments/environment.ts",
Expand Down Expand Up @@ -51,7 +51,7 @@
}
},
"defaults": {
"styleExt": "css",
"styleExt": "scss",
"component": {}
}
}
Empty file modified .editorconfig
100755 → 100644
Empty file.
Empty file modified .gitignore
100755 → 100644
Empty file.
21 changes: 21 additions & 0 deletions .travis-deploy.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
#!/usr/bin/env bash
# go to the directory which contains build artifacts and create a *new* Git repo
# directory may be different based on your particular build process
cd dist
git init

# inside this git repo we'll pretend to be a new user
git config user.name "Travis CI"
git config user.email "tomas.trajan@gmail.com"

# The first and only commit to this new Git repo contains all the
# files present with the commit message "Deploy to GitHub Pages".
git add .
git commit -m "Deploy to GitHub Pages"

# Force push from the current repo's master branch to the remote
# repo's gh-pages branch. (All previous history on the gh-pages branch
# will be lost, since we are overwriting it.) We redirect any output to
# /dev/null to hide any sensitive credential data that might otherwise be exposed.
# tokens GH_TOKEN and GH_REF will be provided as Travis CI environment variables
git push --force --quiet "https://${GH_TOKEN}@${GH_REF}" master:gh-pages > /dev/null 2>&1
8 changes: 8 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
language: node_js
node_js:
- "6"
script:
# run build script specified in package.json
- npm run ci
# call script for deploying of produced artifacts
- bash ./.travis-deploy.sh
31 changes: 4 additions & 27 deletions README.md
100755 → 100644
Original file line number Diff line number Diff line change
@@ -1,28 +1,5 @@
# AngularNgrxMaterialStarter
# 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)
Check out [Demo & Documentation](http://tomastrajan.github.io/angular-ngrx-material-starter/)

This project was generated with [Angular CLI](https://github.com/angular/angular-cli) version 1.0.3.

## Development server

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.

## Code scaffolding

Run `ng generate component component-name` to generate a new component. You can also use `ng generate directive|pipe|service|class|module`.

## Build

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.

## Running unit tests

Run `ng test` to execute the unit tests via [Karma](https://karma-runner.github.io).

## Running end-to-end tests

Run `ng e2e` to execute the end-to-end tests via [Protractor](http://www.protractortest.org/).
Before running the tests make sure you are serving the app via `ng serve`.

## Further help

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).
Built with [Angular CLI](https://github.com/angular/angular-cli)
Empty file modified e2e/app.e2e-spec.ts
100755 → 100644
Empty file.
Empty file modified e2e/app.po.ts
100755 → 100644
Empty file.
Empty file modified e2e/tsconfig.e2e.json
100755 → 100644
Empty file.
2 changes: 2 additions & 0 deletions karma.conf.js
100755 → 100644
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ module.exports = function (config) {
plugins: [
require('karma-jasmine'),
require('karma-chrome-launcher'),
require('karma-phantomjs-launcher'),
require('karma-spec-reporter'),
require('karma-jasmine-html-reporter'),
require('karma-coverage-istanbul-reporter'),
require('@angular/cli/plugins/karma')
Expand Down
21 changes: 18 additions & 3 deletions package.json
100755 → 100644
Original file line number Diff line number Diff line change
Expand Up @@ -8,20 +8,33 @@
"build": "ng build",
"test": "ng test",
"lint": "ng lint",
"e2e": "ng e2e"
"e2e": "ng e2e",
"watch": "ng test --browsers PhantomJS --reporters spec",
"build:prod": "ng build --target production --aot --vendor-chunk --extract-css --output-hashing all --stats-json",
"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",
"clean": "rm -rf ./dist/",
"server": "cd dist && http-server",
"prod": "npm run clean && npm run build:prod && npm run server",
"ci": "npm run clean && ng lint && ng test --browsers PhantomJS --single-run --reporters spec && npm run build:travisci"
},
"private": true,
"dependencies": {
"@angular/animations": "^4.1.1",
"@angular/common": "^4.0.0",
"@angular/compiler": "^4.0.0",
"@angular/core": "^4.0.0",
"@angular/forms": "^4.0.0",
"@angular/http": "^4.0.0",
"@angular/material": "^2.0.0-beta.3",
"@angular/platform-browser": "^4.0.0",
"@angular/platform-browser-dynamic": "^4.0.0",
"@angular/router": "^4.0.0",
"classlist.js": "^1.1.20150312",
"core-js": "^2.4.1",
"hammerjs": "^2.0.8",
"intl": "^1.2.5",
"rxjs": "^5.1.0",
"web-animations-js": "^2.2.5",
"zone.js": "^0.8.4"
},
"devDependencies": {
Expand All @@ -33,11 +46,13 @@
"jasmine-core": "~2.5.2",
"jasmine-spec-reporter": "~3.2.0",
"karma": "~1.4.1",
"karma-chrome-launcher": "~2.1.1",
"karma-chrome-launcher": "~2.0.0",
"karma-cli": "~1.0.1",
"karma-coverage-istanbul-reporter": "^0.2.0",
"karma-jasmine": "~1.1.0",
"karma-jasmine-html-reporter": "^0.2.2",
"karma-coverage-istanbul-reporter": "^0.2.0",
"karma-phantomjs-launcher": "^1.0.4",
"karma-spec-reporter": "0.0.31",
"protractor": "~5.1.0",
"ts-node": "~2.0.0",
"tslint": "~4.5.0",
Expand Down
Empty file modified protractor.conf.js
100755 → 100644
Empty file.
2 changes: 2 additions & 0 deletions src/app/app.component.html
100755 → 100644
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
<h1>
{{title}}

<button md-raised-button>Raised button</button>
</h1>
File renamed without changes.
Empty file modified src/app/app.component.spec.ts
100755 → 100644
Empty file.
2 changes: 1 addition & 1 deletion src/app/app.component.ts
100755 → 100644
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { Component } from '@angular/core';
@Component({
selector: 'app-root',
templateUrl: './app.component.html',
styleUrls: ['./app.component.css']
styleUrls: ['./app.component.scss']
})
export class AppComponent {
title = 'app works!';
Expand Down
14 changes: 10 additions & 4 deletions src/app/app.module.ts
100755 → 100644
Original file line number Diff line number Diff line change
@@ -1,18 +1,24 @@
import 'hammerjs';
import { BrowserModule } from '@angular/platform-browser';
import { NgModule } from '@angular/core';
import { FormsModule } from '@angular/forms';
import { HttpModule } from '@angular/http';
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
import { MdButtonModule } from '@angular/material';


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

@NgModule({
declarations: [
AppComponent
],
imports: [
BrowserModule,
FormsModule,
HttpModule
HttpModule,
BrowserAnimationsModule,
MdButtonModule
],
declarations: [
AppComponent
],
providers: [],
bootstrap: [AppComponent]
Expand Down
Empty file modified src/assets/.gitkeep
100755 → 100644
Empty file.
Empty file modified src/environments/environment.prod.ts
100755 → 100644
Empty file.
Empty file modified src/environments/environment.ts
100755 → 100644
Empty file.
Empty file modified src/favicon.ico
100755 → 100644
Empty file.
1 change: 1 addition & 0 deletions src/index.html
100755 → 100644
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@

<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="icon" type="image/x-icon" href="favicon.ico">
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
</head>
<body>
<app-root>Loading...</app-root>
Expand Down
Empty file modified src/main.ts
100755 → 100644
Empty file.
34 changes: 17 additions & 17 deletions src/polyfills.ts
100755 → 100644
Original file line number Diff line number Diff line change
Expand Up @@ -19,22 +19,22 @@
*/

/** IE9, IE10 and IE11 requires all of the following polyfills. **/
// import 'core-js/es6/symbol';
// import 'core-js/es6/object';
// import 'core-js/es6/function';
// import 'core-js/es6/parse-int';
// import 'core-js/es6/parse-float';
// import 'core-js/es6/number';
// import 'core-js/es6/math';
// import 'core-js/es6/string';
// import 'core-js/es6/date';
// import 'core-js/es6/array';
// import 'core-js/es6/regexp';
// import 'core-js/es6/map';
// import 'core-js/es6/set';
import 'core-js/es6/symbol';
import 'core-js/es6/object';
import 'core-js/es6/function';
import 'core-js/es6/parse-int';
import 'core-js/es6/parse-float';
import 'core-js/es6/number';
import 'core-js/es6/math';
import 'core-js/es6/string';
import 'core-js/es6/date';
import 'core-js/es6/array';
import 'core-js/es6/regexp';
import 'core-js/es6/map';
import 'core-js/es6/set';

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

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


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



Expand All @@ -65,8 +65,8 @@ import 'zone.js/dist/zone'; // Included with Angular CLI.
* Date, currency, decimal and percent pipes.
* Needed for: All but Chrome, Firefox, Edge, IE11 and Safari 10
*/
// import 'intl'; // Run `npm install --save intl`.
import 'intl'; // Run `npm install --save intl`.
/**
* Need to import at least one locale-data with intl.
*/
// import 'intl/locale-data/jsonp/en';
import 'intl/locale-data/jsonp/en';
1 change: 1 addition & 0 deletions src/styles.css → src/styles.scss
100755 → 100644
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
/* You can add global styles to this file, and also import other style files */
@import '~@angular/material/prebuilt-themes/deeppurple-amber.css';
Empty file modified src/test.ts
100755 → 100644
Empty file.
Empty file modified src/tsconfig.app.json
100755 → 100644
Empty file.
Empty file modified src/tsconfig.spec.json
100755 → 100644
Empty file.
Empty file modified src/typings.d.ts
100755 → 100644
Empty file.
Empty file modified tsconfig.json
100755 → 100644
Empty file.
Empty file modified tslint.json
100755 → 100644
Empty file.

0 comments on commit 3ea3e3f

Please sign in to comment.