This repo showcases the installation of a Svelte/Sapper app backed by firebase functions. It doesn't use express nor polka (although it can me easily added). It only use the auto-generated sapper middleware as the main firebase function handler.
src/client.js and add your firebase stuff/config..firebaserc by coping the given example:
cp .firebaserc.example .firebaserc and complete with your stuff.firebase.json file by coping the given example:
cp firebase.example.json firebase.json and complete with your stuff.$ npm run build-dev && cd functions && npm run serve
The above will run:
$ NODE_ENV=development sapper build: builds a dev version of your
sapper/svelte app.$ firebase serve: run your firebase project locally.# build for production
$ npm run build
$ cd functions && npm run deploy