Use make
to build, serve and deploy. For example:
$ make install
to install everything necessary$ make build
to build the site from source$ make serve
to develop the site onlocalhost:3000
with a fast edit-refresh cycle, using BrowserSync$ make deploy
to upload to Firebase$ make clean
to clean up all generated files, useful for a clean build
The homepage has a video screencast of the game in action. To get it, record a device screen with the correct screen ratio (480 x 984). Then compress the video using something like VideoSmaller with width of 480 pixels. (The site has better results than whichever command line tool and preset I've tried so far.)
Before deploying any changes to CSS, images or other media linked in HTML or CSS, update query string in all requests for such assets. Make sure all requests for a file use the same query string, eg.:
<link rel="preload" href="/css/main.min.css?v=2019021201" as="style" />
<!-- … -->
<link rel="stylesheet" href="/css/main.min.css?v=2019021201" />
This will force browsers to download the assets even if they had been cached before (may not work for proxy servers that strip query strings).
Always check that links work before deployment. Recommended approach:
- Install Dart SDK,
and make sure it's in
$PATH
- Install
linkcheck
viapub global activate linkcheck
- Start the local server via
make serve
- Run
linkcheck
vialinkcheck :5000
(this checkslocalhost:5000
) - (Optionally) Check external links with
linkcheck :5000 -e