Giter Site home page Giter Site logo

angular2-website-routes's Introduction

Building an Angular 2 Website Using Routes

This is a simple Angular 2 website using the brand new router. It demonstrates how to build components, configure routes, inject services, and use the @Input decorator to bind properties to components.

Dependencies

  • You must have node and npm installed (via brew install node or NodeJS.org);
  • You must also have typings installed globally via npm i -g typings
  • Be sure that you have typings version 1.x

Getting Started

git clone https://github.com/simpulton/angular2-website-routes.git
cd angular2-website-routes
npm i
typings install
npm start

Then navigate your browser to http://localhost:3001 and use the app.

Testing

The test setup includes webpack.test.config.js, spec-bundle.js, and karma.conf.js. To run unit tests, execute npm test in your terminal.

angular2-website-routes's People

Contributors

hendrixer avatar imichelakos avatar jdgarvey avatar patrickjs avatar pe8ter avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

angular2-website-routes's Issues

start up error in sub proj: webpack-dev-server

Hi, I see the following error after running your recommended init routine. Recommended workarounds or fix?

-- init

git clone https://github.com/simpulton/angular2-website-routes.git
cd angular2-website-routes
npm i
typings install
npm start

-- error

[email protected] start G:\Workx\angular2-website-routes
webpack-dev-server --inline --colors --watch --display-error-details --display-cached --port 3001 --hot

'webpack-dev-server' is not recognized as an internal or external command,
operable program or batch file.

npm ERR! [email protected] start: webpack-dev-server --inline --colors --watch --display-error-details --display -cached --port 3001 --hot
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] start script.
npm ERR! This is most likely a problem with the fem-ng2-simple-app package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! webpack-dev-server --inline --colors --watch --display-error-details --display-cached --port 3001 --hot
npm ERR! You can get their info via:
npm ERR! npm owner ls fem-ng2-simple-app
npm ERR! There is likely additional logging output above.
npm ERR! System Windows_NT 10.0.10586
npm ERR! command "C:\Program Files\nodejs\node.exe" "C:\ProgramData\chocolatey\lib\npm\tools\node_modules\npm
\bin\npm-cli.js" "start"
npm ERR! cwd G:\Workx\angular2-website-routes
npm ERR! node -v v6.5.0
npm ERR! npm -v 1.4.9
npm ERR! code ELIFECYCLE

npm install fails

npm install

npm ERR! Darwin 14.5.0
npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "install"
npm ERR! node v4.4.5
npm ERR! npm v2.15.5
npm ERR! code EPEERINVALID

npm ERR! peerinvalid The package [email protected] does not satisfy its siblings' peerDependencies requirements!
npm ERR! peerinvalid Peer @angular/[email protected] wants [email protected]

npm ERR! Please include the following file with any support request:
npm ERR! /Users/jwalters1/Downloads/angular2-website-routes-master/npm-debug.log

fem-simple app isn't working

Just cloned the fem simple app repo from the workshop, it's not building, and I can't seem to figure out how to fix it.

Can't find some typings

ERROR in [default] C:/APP/angular2-website-routes/app/about/about.component.ts:6:12
Cannot find name ‘require’.
ERROR in [default] C:/APP/angular2-website-routes/app/app.component.ts:11:12
Cannot find name ‘require’.
ERROR in [default] C:/APP/angular2-website-routes/app/app.component.ts:12:11
Cannot find name ‘require’.
ERROR in [default] C:/APP/angular2-website-routes/app/experiments/experiment-details/experiment.detail.component.ts:6:12
Cannot find name ‘require’.
ERROR in [default] C:/APP/angular2-website-routes/app/experiments/experiments.component.ts:10:12
Cannot find name ‘require’.
ERROR in [default] C:/APP/angular2-website-routes/app/home/home.component.ts:6:12
Cannot find name ‘require’.
ERROR in [default] C:/APP/angular2-website-routes/node_modules/@angular/common/src/directives/ng_class.d.ts:72:34
Cannot find name ‘Set’.
ERROR in [default] C:/APP/angular2-website-routes/node_modules/@angular/common/src/facade/async.d.ts:27:32
Cannot find name ‘Promise’.

etc

ERROR in [default] C:/APP/angular2-website-routes/node_modules/rxjs/Observable.d.ts:66:59
Cannot find name ‘Promise’.
ERROR in [default] C:/APP/angular2-website-routes/node_modules/rxjs/Observable.d.ts:66:69
Cannot find name ‘Promise’.
webpack: Failed to compile.

error installing npm "error Windows_NT 6.1.7601"

I have download fem-ng2-simple-app-master project from github.
when i tired to install in give me this error

62066 error Windows_NT 6.1.7601
62067 error argv "C:\Program Files\nodejs\node.exe" "C:\Program Files\nodejs\node_modules\npm\bin\npm-cli.js" "install"
62068 error node v6.11.2
62069 error npm v3.10.10
62070 error code ELIFECYCLE
62071 error [email protected] install: node install.js
62071 error Exit status 1
62072 error Failed at the [email protected] install script 'node install.js'.
62072 error Make sure you have the latest version of node.js and npm installed.
62072 error If you do, this is most likely a problem with the phantomjs-prebuilt package,
62072 error not with npm itself.
62072 error Tell the author that this fails on your system:
62072 error node install.js
62072 error You can get information on how to open an issue for this project with:
62072 error npm bugs phantomjs-prebuilt
62072 error Or if that isn't available, you can get their info via:
62072 error npm owner ls phantomjs-prebuilt
62072 error There is likely additional logging output above.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.