Coder Social home page Coder Social logo

syedpeer / boilerplate-handlebars-pwa Goto Github PK

View Code? Open in Web Editor NEW

This project forked from hrsetyono/boilerplate-handlebars-pwa

0.0 1.0 0.0 328 KB

A very simple Handlebars PWA boilerplate. Demo: https://test.thesyne.com

CSS 31.59% JavaScript 56.25% HTML 12.16%

boilerplate-handlebars-pwa's Introduction

Handlebars PWA Boilerplate

PWA (Progressive Web App) Boilerplate for my favorite templating engine: Handlebars!

It's a very simple engine and has very low learning curve.

The Demo App

This is a blog app that's pulling data from my Wordpress.com account.

  • You can use your own account by changing API_BASE variable in /assets/js/helpers.js.

HOW TO RUN

  1. Install "Web Server for Chrome" via Chrome Market.
  2. Point this project directory and start the Server.
  3. Click the Web server URL.

To make debug easier, open Chrome DevTools > Application tab > Service Worker sidebar > tick "Update on reload".

Features

  1. SIMPLE HTML & JS - No compiler, no headache.

  2. WORKS OFFLINE - Loaded images and JSON data pulled using H_API.get() is automatically cached.

    Image cache in Demo app is hardcoded to only work with WordPress.com site.

    Change IMAGE_URL_INDICATOR in /service-worker.js to part of your URL that indicate an image. For example self-install WordPress is /wp-content/uploads/.

  3. UPDATE PROMPT - Triggered when there is any changes to service-worker.js.

  4. WEB PUSH NOTIFICATION - Require a lot of setups.

    • First unncomment line 11 and 12 in /assets/js/app-worker.js.
    • Then you need to setup Push server. Read here for example using WordPress.
    • Change PUSH_PUBLIC_KEY and PUSH_SAVE_ENDPOINT in /assets/js/helpers.js to fit yours.

Useful Links

  1. Edje Documentation
  2. Edje Wordpress Documentation
  3. How to compile Sass files
  4. How to debug mobile browser

boilerplate-handlebars-pwa's People

Contributors

hrsetyono avatar

Watchers

Syed Peer avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.