Skip to main content

Standard Library

txiki.js includes a standard library with the following modules:

ModuleDescription
tjs:assertAssertion utilities
tjs:ffiForeign function interface
tjs:getoptsCommand-line option parsing
tjs:hashingHashing functions
tjs:ipaddrIP address manipulation
tjs:pathPath utilities
tjs:posix-socketLow-level POSIX socket API
tjs:sqliteSQLite database interface
tjs:uuidUUID generation
tjs:wasiWebAssembly System Interface

See the API Reference for detailed documentation on each module.

Import them using the tjs: prefix:

import { test } from 'tjs:assert';
import { parse } from 'tjs:path';
import { Database } from 'tjs:sqlite';