Skip to content

BosH9/angular-pwa-sample

 
 

Repository files navigation

Actions status Dependency status Dev Dependency status Known Vulnerabilities

angular-pwa-sample

lightouse

This is a PWA sample using Angular CLI.

This sample contains following features.

  • Angular Service Worker
  • App Shell with Angular Universal

Tutorial

  1. Install Angular CLI
$ npm i -g @angular/cli
  1. Create an app
$ ng new my-app --routing --style=css
$ cd my-app
  1. Add service worker
$ ng add @angular/pwa
  1. Generate App Shell
$ ng g app-shell --client-project=my-app
  1. Run ng run to build the app
$ ng run my-app:app-shell --configuration=production

Congratulations ! Your Angular application is built in dist/my-app/browser.

You can see the app by using a static file server.

$ npx serve -s dist/my-app/browser

Releases

No releases published

Packages

No packages published

Languages

  • HTML 53.7%
  • TypeScript 27.4%
  • CSS 12.1%
  • JavaScript 6.8%