Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/puku0x/angular-pwa-sample
Angular PWA Sample
https://github.com/puku0x/angular-pwa-sample
angular angular-cli pwa service-worker
Last synced: about 1 month ago
JSON representation
Angular PWA Sample
- Host: GitHub
- URL: https://github.com/puku0x/angular-pwa-sample
- Owner: puku0x
- Created: 2017-12-17T03:40:29.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2023-02-03T04:48:54.000Z (almost 2 years ago)
- Last Synced: 2024-10-04T19:10:59.824Z (about 1 month ago)
- Topics: angular, angular-cli, pwa, service-worker
- Language: HTML
- Homepage: https://angular-pwa-38ba5.firebaseapp.com
- Size: 2.62 MB
- Stars: 40
- Watchers: 4
- Forks: 15
- Open Issues: 7
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
[![Actions status][actions-image]][actions-url]
[![Dependency status][david-dm-image]][david-dm-url]
[![Dev Dependency status][david-dm-dev-image]][david-dm-dev-url]
[![Known Vulnerabilities][snyk-image]][snyk-url]# angular-pwa-sample
![lightouse](./lighthouse.png)
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
```shell
$ npm i -g @angular/cli
```2. Create an app
```shell
$ ng new my-app --routing --style=css
$ cd my-app
```3. Add service worker
```shell
$ ng add @angular/pwa
```4. Generate App Shell
```shell
$ ng g app-shell --project=my-app
```5. Run `ng run` to build the app
```shell
$ ng run my-app:app-shell
```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
```[actions-url]: https://github.com/puku0x/angular-pwa-sample/actions
[actions-image]: https://github.com/puku0x/angular-pwa-sample/workflows/CI/badge.svg
[david-dm-url]: https://david-dm.org/puku0x/angular-pwa-sample
[david-dm-image]: https://david-dm.org/puku0x/angular-pwa-sample.svg
[david-dm-dev-url]: https://david-dm.org/puku0x/angular-pwa-sample?type=dev
[david-dm-dev-image]: https://david-dm.org/puku0x/angular-pwa-sample/dev-status.svg
[snyk-url]: https://snyk.io/test/github/puku0x/angular-pwa-sample
[snyk-image]: https://snyk.io/test/github/puku0x/angular-pwa-sample/badge.svg