Zero dependencies · ESM-first · Tree-shakable

jQuery,
reimagined
for the modern web.

A familiar chainable API powered by modern Web APIs. Lightweight, modular, ESM-first and built for today's browsers. The power you remember, the platform you have now.

◼︎ v1.0.0 ◼︎ MIT License ◼︎ ~6—8 KB gzip ◼︎ TypeScript ready ◼︎ npm install flash.js
Try it live flash.js
npm install flash.js
javascript — ESM
import { F } from "flash.js";

F(".button")
  .addClass("active")
  .on("click", () => {
    F(".message").text("Hello, FLASH.js!");
  });
Live preview powered by FLASH.js
Click “Run example—” →
.message — waiting
Built for querySelectorAllfetch + AbortControllerWeb Animations APIIntersectionObserverMutationObserverResizeObserver

Familiar. Modern. Fast.

jQuery's DX without jQuery's weight. Every interaction below runs on real FLASH.js — inspect the source, it's dogfooded.

Explore docs →
◈

Familiar API

F(".card").addClass("active") — chaining, selectors, traversal you already know.

⬢

Modern Web APIs

Native fetch, classList, CustomEvent, Observers — no shims.

◎

Zero Dependencies

Single file, no peer deps. Works via CDN, ESM, or CJS.

flash.js — 6—8 KB gzip
⬣

Tree-Shakable

import { http } from "flash.js/http" — only what you use is bundled.

⬔

ESM First

sideEffects: false + subpath exports. Vite / Rollup / esbuild ready.

◆

TypeScript Ready

Full flash.d.ts with FlashCollection generics and overloads.

#demo-card — target for feature demos
storage output →

Live code — real FLASH.js, no fakes.

Every snippet executes against the actual library. Open DevTools — no jQuery, no duplicate abstraction.

js
F(".card").addClass("active");
F("#app").html("<h1>Hello</h1>");
F(".item").attr("data-ready","true").css({ opacity: 1 });
→ watch #demo-card
js
F("button").on("click", handler);
F(document).on("click", ".btn", handler); // delegation
F("button").trigger("custom:event", { detail: 123 });
js
const user = await F.http.json("/api/user/42");
const res = await F.http.get("/api/data", { timeout: 5000 });
await F.http.post("/api/user", JSON.stringify({ name: "Ada" }));
—
js
F.storage.set("theme", "dark");
F.storage.get("theme"); // "dark"
F.storage.session.set("draft", { ... });
→ persists via localStorage
js
await F("#box").animate(
  { opacity: [0,1], transform: ["translateY(8px)","translateY(0)"] },
  { duration: 300, easing: "ease-out" }
);
await F("#box").fadeIn(); // or fadeOut / slideDown / slideUp
js
F.toast("Saved!", "success");
await F.alert("Done", "FLASH.js");
const ok = await F.confirm("Delete?", "Confirm");
F.loading(true); await work(); F.loading(false);
await F.modal({ title:"Hello", message:"...", actions:[...] })
IntersectionObserver demo — scroll this into view
visible: —

Designed for the web that exists today.

FLASH.js doesn't repackage old shims. It composes the platform: querySelectorAll, classList, fetch, AbortController, CustomEvent, MutationObserver, Web Animations API — with a chainable DX you already know.

bash
npm install flash.js

# CDN
<script src="https://unpkg.com/flash.js/dist/flash.min.js"></script>
<script>F.toast("hello")</script>