NOTE: this repo is an early iteration of elm-webapp. ideally we re-introduce a cloudflare workers runtime to elm-webapp instead
Elm is a perfect fit actually, since you can hardly do anything other than HTTP and accessing the Cloudflare KV store.
- After logging into cloudflare click on
Get started with Workers, or go tohttps://dash.cloudflare.com/{account_id}/workers/kv/namespaces - Click on
KVand add a namespace; copy and paste theidintowrangler.tomlunder[[kv-namespaces]] > id - Click on
Workerstab on top and create a worker; set the worker name in your wrangler.toml - Click on
{} Editor>KVtab >+ Add bindingbutton to bind your KV namespace to a JS global variable name (the variable name can be different from the namespace name)- i think you'll need to
Save and deploybutton below for it to take effect
- i think you'll need to
After these are setup, you can make preview locally; your browser will automatically load a page running your worker on Cloudflare.
