r/javascript • u/Actual_South_2484 • 15h ago
r/javascript • u/Ok-Salt2274 • 12h ago
I made a map where you drag a year slider and see who ruled each state (1000 BC to today, every claim sourced)
whoruled.nitinsijwali.comFree and open source, no signup. The theme changes with the era. Borders before ~500 BC are approximate, and leader data is thin before 1600, so corrections are very welcome. Link in comments.
r/javascript • u/HiAxiAcee • 14h ago
made a CLI that generates a typed client from a HAR capture — here's what the output looks like
github.combuilt this after getting tired of manually writing fetch wrappers for sites with no public API. point it at a HAR file (browser network capture) and it generates a typed client.
input: a captured request to something like `GET /users/42`
output (simplified):
export interface User {
id: number;
name: string;
email: string;
}
export async function getUser(id: number): Promise<User> {
const res = await fetch(`${baseUrl}/users/${id}`);
if (!res.ok) throw new ApiError(res.status, await res.text());
return res.json();
}
it infers the types from the actual response bodies in the capture, templates dynamic path segments like `{id}`, and also generates an OpenAPI spec + mock server from the same HAR.
also tries to catch GraphQL/tRPC/JSON-RPC calls instead of treating everything as REST, and strips anything sensitive (tokens, cookies) from the captured data before it reaches the generated code.
npx har2sdk capture.har -o ./sdk
repo: https://github.com/Mersbyte/har2sdk
curious what people think of the generated code style, or if anyone's hit an API shape it chokes on.
r/javascript • u/Martinsos • 19h ago
Wasp web framework v1.0 is coming: the roadmap and what changes
wasp.shr/javascript • u/Vinserello • 18h ago
3 drop-in JS widgets (forecast, dashboard, anomaly detection) that run 100% in the browser via WASM
github.comSpent the last months building
@datastripes/forecast
@datastripes/dashboard
@datastripes/anomaly
These are framework-agnostic npm packages (React, Vue, Angular, or a plain custom element) that add time-series forecasting, an editable dashboard builder, and anomaly detection to any frontend app.
Everything runs client-side via WebAssembly, so no user data ever hits a server except a license check without a backend to deploy, no Python microservice.
Would genuinely love feedback from anyone who's had to build this kind of feature in-house.
https://datastripes.com/forecast-widget/