global
js/globals/global.ts
internal:globals/global — web-standard globals registry.
A barrel that collects every web-platform API fino installs on
globalThis. Runtime bootstrap (js/internal/bootstrap.ts) imports the
named exports and defines each one as a global property, so user scripts
can use URL, fetch, ReadableStream, and friends without an explicit
import — just like browsers. Each API is implemented in its own sibling
module under js/globals/ (Headers, Request, and Response come from
internal:net/http/wire); the WHATWG/W3C spec links live with each
implementation.
Why a separate module?
Separating global registration from the individual implementations keeps
each module self-contained. The URL implementation does not need to know
or care that URL ends up on globalThis; that is this registry's
concern. To add a global, export it here and add it to bootstrap's
registration table — the table is an explicit object literal, so a new
export is not picked up automatically.
What is NOT here
setTimeout/setInterval/setImmediate/queueMicrotask/performance— also set on globalThis by runtime bootstrap but sourced fromglobals/time.ts, because they are wired to a specific loop handle.process— available asfino:processbut not on globalThis (fino is not Node.js; prefer explicit imports for process-level APIs).
Not every export here becomes a global, either: _flushPorts is a
bootstrap-only hook that delivers queued MessagePort messages once per
loop turn, and is never assigned to globalThis.
const url = new URL('https://example.com/');
const stream = ReadableStream.from(['chunk']);
const response = await fetch(url.href);
Classes
class Event {
Re-exported from eventtarget.Event.
class CustomEvent extends Event {
Re-exported from eventtarget.CustomEvent.
class EventTarget {
Re-exported from eventtarget.EventTarget.
class CountQueuingStrategy {
Re-exported from webstreams.CountQueuingStrategy.
class ByteLengthQueuingStrategy {
Re-exported from webstreams.ByteLengthQueuingStrategy.
class ReadableStreamDefaultController {
Re-exported from webstreams.ReadableStreamDefaultController.
class ReadableByteStreamController {
Re-exported from webstreams.ReadableByteStreamController.
class ReadableStreamBYOBRequest {
Re-exported from webstreams.ReadableStreamBYOBRequest.
class ReadableStream {
Re-exported from webstreams.ReadableStream.
class ReadableStreamDefaultReader {
Re-exported from webstreams.ReadableStreamDefaultReader.
class ReadableStreamBYOBReader {
Re-exported from webstreams.ReadableStreamBYOBReader.
class WritableStreamDefaultController {
Re-exported from webstreams.WritableStreamDefaultController.
class WritableStream {
Re-exported from webstreams.WritableStream.
class WritableStreamDefaultWriter {
Re-exported from webstreams.WritableStreamDefaultWriter.
class TransformStreamDefaultController {
Re-exported from webstreams.TransformStreamDefaultController.
class TransformStream {
Re-exported from webstreams.TransformStream.
class AbortController {
Re-exported from abort.AbortController.
class AbortSignal extends EventTarget {
Re-exported from abort.AbortSignal.
class Blob {
Re-exported from blob.Blob.
class File extends Blob {
Re-exported from blob.File.
class FileReader extends EventTarget {
Re-exported from blob.FileReader.
class DOMException extends Error {
Re-exported from js/globals/encoding.DOMException.
class QuotaExceededError extends DOMException {
Re-exported from js/globals/encoding.QuotaExceededError.
class TextEncoder {
Re-exported from js/globals/encoding.TextEncoder.
class TextDecoder {
Re-exported from js/globals/encoding.TextDecoder.
class FormData {
Re-exported from formdata.FormData.
class URL {
Re-exported from url.URL.
class URLSearchParams {
Re-exported from url.URLSearchParams.
class URLPattern {
Re-exported from urlpattern.URLPattern.
class CryptoKey {
Re-exported from js/globals/crypto.CryptoKey.
class CompressionStream {
Re-exported from compression-streams.CompressionStream.
class DecompressionStream {
Re-exported from compression-streams.DecompressionStream.
class EventSource extends EventTarget {
Re-exported from eventsource.EventSource.
class WebSocket extends EventTarget {
Re-exported from js/net/http/websocket.WebSocket.
class CloseEvent extends Event {
Re-exported from js/net/http/websocket.CloseEvent.
class ErrorEvent extends Event {
Re-exported from js/net/http/websocket.ErrorEvent.
class WebTransport {
Re-exported from js/net/http/webtransport.WebTransport.
class WebTransportDatagramDuplexStream {
Re-exported from js/net/http/webtransport.WebTransportDatagramDuplexStream.
class MessageEvent extends Event {
Re-exported from js/globals/messaging.MessageEvent.
class MessagePort extends EventTarget {
Re-exported from js/globals/messaging.MessagePort.
class MessageChannel {
Re-exported from js/globals/messaging.MessageChannel.
class BroadcastChannel extends EventTarget {
Re-exported from broadcast-channel.BroadcastChannel.
Interfaces
interface AddEventListenerOptions {
Re-exported from eventtarget.AddEventListenerOptions.
interface FileList {
Re-exported from blob.FileList.
interface FetchInit {
Re-exported from js/globals/fetch.FetchInit.
Types
type EventCallback = ((event: Event) => void) | {
handleEvent(event: Event): void;
}
Re-exported from eventtarget.EventCallback.
type FormDataEntryValue = string | File
Re-exported from formdata.FormDataEntryValue.
Functions
function atob(encodedData: string): string
Re-exported from js/globals/encoding.atob.
function btoa(data: string): string
Re-exported from js/globals/encoding.btoa.
function structuredClone<T>(value: T, options?: {
transfer?: ArrayBuffer[];
}): T
Re-exported from js/globals/encoding.structuredClone.
async function fetch(input: string | Request, init?: FetchInit): Promise<Response>
Re-exported from js/globals/fetch.fetch.
Constants
const crypto: Crypto
Re-exported from js/globals/crypto.crypto.
const cryptoAvailable
Re-exported from js/globals/crypto.cryptoAvailable.
const tlsAvailable
Re-exported from js/globals/crypto.tlsAvailable.