Skip to content

laranatech/electrostatic

Electrostatic — ssr and ssg

Simple app to generate and serve static content.More info in this article (ru).

Installation

  1. install the package go install larana.tech/go/electrostatic@latest
  2. initialize the project electrostatic -m init -r /path/to/source
  3. edit template.html and config.toml as you wish
  4. You are ready to go!

Usage

This app supports 2 modes:

SSMG (SSR) mode (recomended for development)

Just run it with electrostatic -m serve -r /path/to/source

SSG mode

Build it with electrostatic -m export -r /paht/to/source. Your static site will be written in ./dist directory. Copy it to your static server and that's all.

Note about routing

Links will be created in /posts/2026-02-27-post-title format, not /posts/2026-02-27-post-title.html (the .html will be missing).

If you want them to work, you'll need to config your server config.

Check out this issue: #18

Credits

Evgenii Kucheriavyi

Support on boosty or patreon.