Static site hosting via tangled
JavaScript 100.0%
Other 0.1%
6 1 0

Clone this repository

https://tangled.org/gracekind.net/tangled-pages
git@knot.gracekind.net:gracekind.net/tangled-pages

For self-hosted knots, clone URLs may differ based on your setup.

README.md

tangled-pages#

A simple way to host a website via a tangled repo. You can run it as a cloudflare worker or as an express server.

Setup#

Create .env pointing to the repo you want to host:

KNOT_DOMAIN=knot.gracekind.net
OWNER_DID=did:plc:p572wxnsuoogcrhlfrlizlrb
REPO_NAME=tangled-pages-example

Run server:

npm install
npm start

Config#

You can configure the site by creating a pages_config.yaml file in the root of the repo.

baseDir: "/public"
notFoundFilepath: "404.html"

Limitations#

It fetches files from the repo on request, so it might be slow. In the future, we could cache the files and use a CI to update the cache.