A progressive Hacker News client built with Angular
⚡ Fast: Service Worker App Shell + Dynamic Content model to achieve faster load times with and without a network.
📱 Responsive: Completely responsive UI that can be installed to your mobile home screen to provide a native feel.
🚀 Progressive: Lighthouse score of 100/100.
This app uses a Service Worker to load quickly and work offline.
sw-precache
is used to serve local static resources (App Shell) cache first.sw-toolbox
is used to handle requests using thenetworkFirst
strategy. If a request fails, the app will fulfill the request from the cache. This means previously loaded pages will now work offline.
With Chromium based browsers for Android (Chrome, Opera, etc...), Angular 2 HN includes a Web App Manifest that allows you to install to your homescreen.
Built in theme engine!
Current themes:
- Default
- Night
- Black (AMOLED)
More to come!
- Realtime updating using the Firebase SDK (may need to add option to settings so service worker can still rely on REST endpoints)
- Server side rendering
Feel free to send me feedback on twitter or file an issue! Feature requests are always welcome.
Note: This project has been ejected (with AOT + production settings) in order to customize Webpack configurations.
- Clone or download the repo
npm install
npm start
to run the application with webpack-dev-server ornpm build
to kick off a fresh build and update the output directory (dist/
)
Note: Any Service Worker changes will not be reflected when you run the application locally in development. To test service worker changes:
npm build
npm run precache
to generate the service worker filenpm run static-serve
to load the application along with the service worker asset using live-server
A million thanks to some awesome people :)