FeaturesTemplatesShowcaseTownie
AI
BlogDocsPricing
Log inSign up
std
stdutils
Val Town Project Utilities
Public
Like
2
utils
Home
Code
7
file
1
parseImportMeta
3
serve-file
1
static
1
test
2
README.md
S
index.ts
Branches
2
Pull requests
1
Remixes
4
History
Environment variables
Val Town is a collaborative website to build and scale JavaScript apps.
Deploy APIs, crons, & store data – all from the browser, and deployed in miliseconds.
Sign up now
Code
/
Code
/
Search
README.md

Val Town Project Utilities

These utils are very rapidly developing, so expect breaking changes.

  • file - reading files and directories in Projects
  • parseImportMeta - parse project info out of its importa.meta.url
  • serve-file - return Project files as HTTP Responses with proper content-types
  • test - a little framework for running tests and displaying the results as HTML and a badge

Usage

Import them with version pins to be safe:

Create val
import { parseProject, serveFile } from "https://esm.town/v/std/utils/index.ts";

Example usage: https://www.val.town/x/std/reactHonoStarter/code/backend/index.ts

Code
fileparseImportMetaserve-filestatictestREADME.md
S
index.ts
Go to top
X (Twitter)
Discord community
GitHub discussions
YouTube channel
Bluesky
Product
FeaturesPricing
Developers
DocsStatusAPI ExamplesNPM Package Examples
Explore
ShowcaseTemplatesNewest ValsTrending ValsNewsletter
Company
AboutBlogCareersBrandhi@val.town
Terms of usePrivacy policyAbuse contact
© 2025 Val Town, Inc.