aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--blog/progressive-webapp-conversion-2019-01-26.md2
-rw-r--r--cmd/site/main.go7
2 files changed, 6 insertions, 3 deletions
diff --git a/blog/progressive-webapp-conversion-2019-01-26.md b/blog/progressive-webapp-conversion-2019-01-26.md
index c2934c0..4fe8cf3 100644
--- a/blog/progressive-webapp-conversion-2019-01-26.md
+++ b/blog/progressive-webapp-conversion-2019-01-26.md
@@ -182,7 +182,7 @@ And then deploy these changes – you should see your service worker posting log
## Deploying
-Deploying your web app is going to be specific to how your app is developed. If you don't have a place to put it already, [Heroku](https://heroku.com) offers a nice and simple way to host progressive web apps. Using [the static buildpack](https://github.com/heroku/heroku-buildpack-static) is the fastest way to deploy a static application already built to Javascript and HTML. You can look at [my fork of GraphvizOnline](https://github.com/Xe/GraphvizOnline) for an example of a Heroku-compatible progressive web app. Note that if you deploy this, you will need to edit the start URL in [the manifest](https://github.com/Xe/GraphvizOnline/blob/master/manifest.json#L8) to the URL that will reach the deployed website – for instance, `sandy-beach-3033.herokuapp.com`.
+Deploying your web app is going to be specific to how your app is developed. If you don't have a place to put it already, [Heroku](https://heroku.com) offers a nice and simple way to host progressive web apps. Using [the static buildpack](https://github.com/heroku/heroku-buildpack-static) is the fastest way to deploy a static application already built to Javascript and HTML. You can look at [my fork of GraphvizOnline](https://github.com/Xe/GraphvizOnline) for an example of a Heroku-compatible progressive web app.
## Using Your Progressive Web App
diff --git a/cmd/site/main.go b/cmd/site/main.go
index 3791585..14aec02 100644
--- a/cmd/site/main.go
+++ b/cmd/site/main.go
@@ -13,10 +13,10 @@ import (
"time"
"github.com/Xe/jsonfeed"
- "within.website/ln"
"github.com/gorilla/feeds"
blackfriday "github.com/russross/blackfriday"
"github.com/tj/front"
+ "within.website/ln"
)
var port = os.Getenv("PORT")
@@ -164,12 +164,15 @@ func Build() (*Site, error) {
s.mux.HandleFunc("/", func(w http.ResponseWriter, r *http.Request) {
if r.URL.Path != "/" {
w.WriteHeader(http.StatusNotFound)
- s.renderTemplatePage("error.html", "can't find " + r.URL.Path).ServeHTTP(w,r)
+ s.renderTemplatePage("error.html", "can't find "+r.URL.Path).ServeHTTP(w, r)
return
}
s.renderTemplatePage("index.html", nil).ServeHTTP(w, r)
})
+ s.mux.HandleFunc("/.within/health", func(w http.ResponseWriter, r *http.Request) {
+ http.Error(w, "OK", http.StatusOK)
+ })
s.mux.Handle("/resume", s.renderTemplatePage("resume.html", s.Resume))
s.mux.Handle("/blog", s.renderTemplatePage("blogindex.html", s.Posts))
s.mux.Handle("/contact", s.renderTemplatePage("contact.html", nil))