To get started developing the API:
Clone the Flourish API demo and follow the instructions to set it up.
Link the local version of the API, then start the API demo:
(cd $WHEREVER/flourish/api && npm link) cd $WHEREVER/flourish-api-demo npm link @flourish/live-api npm start
Start Flourish locally, and obtain a local API key if you don't already have one.
Open the running API demo on http://localhost:8888/?local=1 (NB: the
local=1parameter ensures this is run against your local Flourish server). Enter your local API key when requested.
Finally, to see the effects of your changes: edit the API code in this directory, and run
npm run buildinside
NB: each time you want to see a new change propagate, you'll need to rerun
npm run build and restart the API demo.