Skip to content

Type-safe static site generator in ReScript. Fast compilation with JavaScript ecosystem access.

License

Notifications You must be signed in to change notification settings

hyperpolymath/rescribe-ssg

rescribe-ssg

RSR Compliant poly-ssg License

Type-safe static site generator in ReScript.

ML-family types meet the JavaScript ecosystem.

Who Is This For?

  • ReScript developers who love the language

  • Former BuckleScript users seeking modern tooling

  • Teams wanting type safety without leaving the JS ecosystem

  • Anyone frustrated by runtime type errors in Node SSGs

Why rescribe-ssg?

ML-Family Type Inference

Write code naturally. Types are inferred. Errors are caught at compile time.

let buildPage = (page: page) => {
  let html = page.content->Markdown.toHtml
  html->Template.apply(page.frontmatter)
}
// Types inferred, errors caught

Readable JavaScript Output

The generated JavaScript is readable and debuggable. No runtime overhead from the type system.

Full JS Ecosystem Access

npm packages work seamlessly. Bindings are type-safe. Best of both worlds.

Pattern Matching for Content

Variant types and pattern matching make content handling elegant.

Quick Start

# Install
npm install -g rescribe-ssg

# Create a site
rescribe init my-site
cd my-site

# Build
rescribe build

# Watch mode
rescribe watch

Features

  • Sound type system - if it compiles, it works

  • Variant types - model content precisely

  • Pattern matching - elegant content handling

  • Fast compilation - sub-second rebuilds

  • npm compatibility - use any JS library

Requirements

  • Node.js 18 or later

  • ReScript 11+

Part of poly-ssg

rescribe-ssg is part of the poly-ssg family, unified through MCP integration.

License

AGPL-3.0-or-later

About

Type-safe static site generator in ReScript. Fast compilation with JavaScript ecosystem access.

Topics

Resources

License

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Sponsor this project

Packages

No packages published

Contributors 2

  •  
  •