TypeScript web router designed exclusively for Cloudflare Workers with file-system routing and streaming JSX
Action function for non-GET requests (POST, PUT, DELETE, etc.).
Environment bindings interface. Extend this interface to add your Cloudflare Workers bindings.
Headers function to set response headers based on request context and loader data.
Html type for streaming HTML content with async generation support.
JSX namespace containing type definitions for JSX elements and attributes.
- accesskey
- children
- class
- contenteditable
- dangerouslySetInnerHTML
- dir
- draggable
- hidden
- id
- inert
- lang
- on
- onClick
- onContextmenu
- onDblclick
- onDrag
- onDragend
- onDragenter
- onDragleave
- onDragover
- onDragstart
- onDrop
- onKeydown
- onKeypress
- onKeyup
- onMousedown
- onMousemove
- onMouseout
- onMouseover
- onMouseup
- onMousewheel
- onScroll
- popover
- popoveraction
- popovertarget
- role
- spellcheck
- style
- tabindex
- title
- translate
- a
- abbr
- address
- area
- article
- aside
- audio
- b
- base
- bb
- bdi
- bdo
- blockquote
- body
- br
- button
- canvas
- caption
- cite
- code
- col
- colgroup
- commands
- data
- datalist
- dd
- del
- details
- dfn
- dialog
- div
- dl
- dt
- em
- embed
- feDisplacementMap
- feTurbulence
- fieldset
- figcaption
- figure
- filter
- footer
- form
- h1
- h2
- h3
- h4
- h5
- h6
- head
- header
- hgroup
- hr
- html
- i
- iframe
- img
- input
- ins
- kbd
- keygen
- label
- legend
- li
- link
- main
- map
- mark
- menu
- meta
- meter
- nav
- noscript
- object
- ol
- optgroup
- option
- output
- p
- param
- path
- pre
- progress
- q
- rb
- rp
- rt
- rtc
- ruby
- s
- samp
- script
- section
- select
- small
- source
- span
- strong
- style
- sub
- summary
- sup
- svg
- table
- tbody
- td
- template
- textarea
- tfoot
- th
- thead
- time
- title
- tr
- track
- u
- ul
- var
- video
- wbr
Loader function for GET requests. Fetches data that will be passed to the component.
Route module that can export loader, action, default component, and headers.
Renders an Html value to a string.
Component renderer function that returns JSX.
Route tuple containing a URLPattern and its associated fragments.
Captures the current store and returns a function that runs under it. Useful when scheduling async work that must see the same context.
Injects the client runtime as a module script into the page.
Creates a new Context with the given default value.
Client handler signature for browser-dispatched events.
Creates a new ref with the given initial value.
Streams resolved Suspense content. Define once near the end of . If a strict CSP is used, supply a nonce so the defining script can run.
Runs a function with a fresh context storage Map. Use this to isolate a request or render pass.
Dynamic registry of event helpers backed by the DOM event map.
Tuple representation for a client event binding.
Ensures the default export conforms to the expected handler signature.
Branded string representing a lazily loaded client handler module.
The brand carries the handler type so event helpers can preserve this and event payload inference.
Reference to a client handler, optionally rewritten by bundlers to a module URL.
Generates router and TypeScript types from a file-system based route structure.
Escapes HTML special characters to prevent XSS attacks.
Fragment component for grouping multiple elements without a wrapper.
Core JSX factory function that creates HTML elements or calls component functions.
JSX factory for multiple children (same as jsx in this implementation).
Infers the argument type for action functions with typed route parameters.
Infers the props type for a component based on its module exports.
Infers the type for headers functions with typed parameters and loader data.
Infers the argument type for loader functions with typed route parameters.