Skip to content

jesussobrino/angular2-heroes

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

36 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Angular 2 Heroes Example

Overview

As you can see this repo is following The Angular 2 Heroes tutorial with my ideal folder structure. I don't know if it's the best folder structure, but I like it the most. Specially because I need to change the structure when using server-side rendering with Angular 2.

This repo is divided in several branches, each branch represent a step of the Angular 2 Heroes tutorial:

I would recommend:

  • To Start with step0: git clone https://github.com/jesussobrino/angular2-heroes.git && cd angular2-heroes && git checkout step0
  • Or to follow step by step the Angular 2 tutorial.

Server-Side Rendering

As you can see the step6 branch is using server-side rendering. Unfortunately I didn't know how to apply server-side rendering with lite-server. So I decided to change the package dependencies for using webpack, because I think it's easier to understand.

In this example, you can take a look to the "Network tab" in the Chrome Dev Tools, and see how fast is loaded the initial template in comparison with previous steps.

For more Sever-Side Rendering information, please take a look to Angular Universal.

Prerequisites

Node.js

  • Download and install Node.js.
  • Install the tool dependencies (npm install).

Installing dependencies

The application needs some dependencies, such as Bower, Angular files, etc. You can install these by running:

npm install --global typescript typings
npm install

Or directly:

npm start

Running the app

About

Angular2 Heroes example app

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published