A Progressive web app to make note of places where one can drink coffee. This app was developed by me during the process of learning Progress Web App development with Angular 5.
This project was generated with Angular CLI version 1.6.0.
- PWA Experience
- Installable with icon
- Works with any network status, even offline
- Reloads immediately and has a fast UX
- Can load outside of a browser's UI
-
Use of service worker
-
Use of web app manifest
-
Platform integration
- Modern browser API usage
- Web push notifications
- Geolocation and share functionality
- Integration with native apps
Add form validationAdd error handlingUse IndexedDB to store updates while offlineUse the background sync API for updating the background- Add server-side rendering for the initial view using Angular universal
Create a web push server architectureImprove desktop and tablet viewAuthentication and Database per user
- Angular material
- Angular
- Angular Animations
- Hammerjs for detecting gestures on mobile devices
- Material icons
- NeDB for database storage on server side
- express-nedb-rest adds RESTAPI support for nedb database
-
Angular service worker
This is installed using
npm install --save-dev @angular/service-worker
To test this app,
- Clone this repository and move into coffeeapp.
In order for service worker to work, you need to have angular-cli 1.6.0 installed.
Steps to install angular-cli 1.6.0:
Uninstall previous version of angular-cli
npm uninstall -g @angular/cli
Install angular-cli 1.6.0
npm install -g @angular/cli@latest
Remove node_modules and dist folder from project directory
rm -rf node_modules dist
Install latest angular-cli locally
npm install --save-dev @angular/cli@latest
-
Run
npm install
from the project directory to install dependencies. -
Since, this app uses service worker, we need to use a production build. To create a production build, use
npm run build-prod-ngsw
. -
Install a static server such as SimpleHttpServer.
-
Move into the dist folder and run
simplehttpserver
. -
Go to http://localhost:8000 (8000 is the default port for simplehttpserver) to see the app.