Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/cloudflare/worker-template-static
https://github.com/cloudflare/worker-template-static
Last synced: about 2 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/cloudflare/worker-template-static
- Owner: cloudflare
- Created: 2019-04-26T15:19:28.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2023-03-21T13:17:44.000Z (over 1 year ago)
- Last Synced: 2024-04-27T05:32:18.249Z (5 months ago)
- Language: JavaScript
- Size: 111 KB
- Stars: 14
- Watchers: 2
- Forks: 7
- Open Issues: 6
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- awesome-cloudflare - Static - Generate a static HTML or JSON page from raw strings in your workers script. (Workers / Recipes)
- awesome-cloudflare - Static - Generate a static HTML or JSON page from raw strings in your workers script. (Workers / Recipes)
README
## Static
Generate a static HTML or JSON page from raw strings in your Workers script.
[`index.js`](https://github.com/cloudflare/worker-template-static/blob/master/index.js) is the content of the Workers script.
Live Demos are hosted on `workers-tooling.cf/demos/static`:
[Demo HTML](http://workers-tooling.cf/demos/static/html) | [Demo json](http://workers-tooling.cf/demos/static/json)#### Wrangler
To generate using [wrangler](https://github.com/cloudflare/wrangler)
```
wrangler generate myApp https://github.com/cloudflare/worker-template-static
```#### Serverless
To deploy using serverless add a [`serverless.yml`](https://serverless.com/framework/docs/providers/cloudflare/) file.