Skip to content

SekibOmazic/angular2-rx

Repository files navigation

Angular2 RxJs playground

This repo serves as a playground for Angular2 and RxJs.

Based on angular2-webpack-starter. Good job @gdi2290!

Important notice

This repository is no longer maintained. All examples have been moved to angular2-webpack-starter

Quick start

Clone/Download the repo then edit app.ts inside /src/app/components/app.ts

$ npm start

Getting Started

Dependencies

What you need to run this app:

  • node and npm (brew install node)
  • Ensure you're running the latest versions Node v0.12.2+ and NPM 2.10.0+

Once you have those, you should install these globals with npm install -global:

  • webpack (npm install -global webpack)
  • webpack-dev-server (npm install -global webpack-dev-server)

Installing

  • fork this repo
  • clone your fork
  • npm install to install all dependencies
  • npm run server to start the server

Running the app

After you have installed all dependencies you can now run the app. Run npm server to start a local server using webpack-dev-server which will watch, build (in-memory), and reload for you. The port will be displayed to you as http://localhost:8080.

server

$ npm run server

build files

$ npm run build

watch and build files

$ npm run watch

TypeScript

To take full advantage of TypeScript with autocomplete you would have to install it globally and use an editor with the correct TypeScript plugins.

Use latest TypeScript compiler

TypeScript 1.5 beta includes everything you need. Make sure to upgrade, even if you installed TypeScript previously.

$ npm install -global typescript@^1.5.0-beta

.d.ts Typings

The typings in typings/ are partially autogenerated, partially hand written. All the symbols should be present, but probably have wrong paramaters and missing members. Modify them as you go.

$ npm install -global tsd

You may need to require reference path for your editor to autocomplete correctly

/// <reference path="../../typings/tsd.d.ts" />
/// <reference path="../custom_typings/ng2.d.ts" />

Otherwise including them in tsd.json is prefered

Use a TypeScript-aware editor

We have good experience using these editors:

Todo

  • img for 'X' in tic-tac-toe doesn't load after moving to Angular alpha.30. Makes no sense!
  • Strange TS warnings on autosuggest.ts and github.ts - need to fix that.
  • production/development environments
  • testing
  • e2e
  • production services examples
  • hot-component-reloading

About

A playground for Angular2 and RxJs. Also uses new Router.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published