An isomorphic TypeScript library of
utility functions for parsing and interacting with
twtxt.txt files.
These functions include:
Browser
JSR
NPM
Use the tabs to learn more.
Example parsed file from
/twtxt-demos/demo-hipster-twtxt.txt :
Copyright © 2026 Eric Woodward, released under the MIT License.
A function that takes the constituent parts of a “twt” and generates an extension-compatible hash for it.
A function that parses a twtxt file string, returning an object with information about the file and its owner (including hashes for each twt and any metadata in the file).
Pre-included examples:
/twtxt-demos/demo-hipster-twtxt.txt
/twtxt-demos/demo-pirate-twtxt.txt
/twtxt-demos/demo-sagan-twtxt.txt
Load
Note that CORS restrictions may limit the effectiveness of using this function from another domain.
An async function that fetches a twtxt.txt-compatible file from a URL and parses it into an object
Pre-included examples:
/twtxt-demos/demo-hipster-twtxt.txt
/twtxt-demos/demo-pirate-twtxt.txt
/twtxt-demos/demo-sagan-twtxt.txt
Note that CORS restrictions may limit the effectiveness of using this function from another domain.