Ecosyste.ms: Awesome

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

Awesome Lists | Featured Topics | Projects

https://github.com/adcpd/agularjs2_first_config

Create a first config project using extension & package for AngularJs2 (initial project)
https://github.com/adcpd/agularjs2_first_config

angular2

Last synced: about 6 hours ago
JSON representation

Create a first config project using extension & package for AngularJs2 (initial project)

Awesome Lists containing this project

README

        

# AgularJs2_first_config
Create a first config project using extension & package for AngularJs2 (initial project)

################## STEP TO STEP TO CREATE AN ANGULARJS 2 PROJECT ##################

# create a new project AngularJs :

Next you need to follow this steps :

# create index.html
> touch index.html

# create package.json with defaults
> npm init --yes

# install lite-server
> npm install --save-dev lite-server

# create the file "pakage.json" & execute the command
> npm run lite

################## TYPESCRIPT ##################
And now, we need to install the Typescript into you project NG-2.

# Add this line in the tsconfig.json
"lib": ["es2015", "dom"]

# Add this line in the script > package.json:
"start": "concurrently \"npm run tsc:w\" \"npm run lite\"",

# install the typescript package
> npm install --save-dev typescript @types/node @types/jasmine @types/core-js

# configurate with the same tsconfig.json

################## Angular 2 : Dependencies ##################

To install the dependencies use :
> npm install core-js reflect-metadata zone.js rxjs systemjs --save
or use :
> npm install core-js reflect-metadata zone.js [email protected] systemjs --save

################## Angular 2 : Packages ##################

To install the angular packages use :
> npm install @angular/core @angular/common @angular/compiler @angular/platform-browser @angular/platform-browser-dynamic @angular/forms @angular/http @angular/router --save
> npm i @angular/upgrade

##### Install System.js

create a new file systemjs.config.js and copy the same configuration of my project

Add the dependency in the view " index.html ":









system.import('app').catch(function (e) {
console.error(e);
});