i'm playing figwheel , writing simple single-page app doesn't require server-side intelligence.
in principle, app. placed on static web-server.
but how deploy it? looks main.js in figwheel development environment setting figwheel connection.
what js , html files need put on static server? has figwheel created them, or need create new main.js , index.html? , can find examples?
the documentation great how started using figwheel surprisingly reticent on after you've finished development.
step 1: make production build: lein clean, cljsbuild once min
step 2: put in resources/public
in publicly accessible place.
here script use in example project: https://github.com/timothypratley/whip/blob/master/deploy.sh
the html resources don't change between local development , deployment. thing different compiled artifacts. can deploy in fact development compiled artifacts fine too. reason recommended "production build" when developing locally intermediate js files not stitched together, because faster load changed code browser. deployment, having single compiled artifact better. single compiled js can have advanced optimizations, or simple optimizations depending on how configure builds in project.clj. don't need worry of this, i'm explaining because asked changes.
it might sound strange html page doesn't change @ all, lets explain little more. html page includes compiled js, when running figwheel, if open js see in turn loads other js files. if exit figwheel , clean "production" build, see code goes 1 js file. pretty tricky huh?
that whip project should provide example seeking, please let me know if of unclear.
it uses github pages , deployment target, again need in resources/public directory hosted somewhere. can use similar script deployment target.