@jamsite/jamsite

0.0.30 • Public • Published

jamsite

Jamsite - JAMstack framework where static goes dynamic.

Overview

This package is intended for production use only: jamsite server or static files generation.

See @jamsite/jamsite-dev for development mode.

Usage

Install jamsite-cli globally with npm i -g @jamsite/jamsite-cli.

Execute jamsite start in a folder with site template (e.g. https://github.com/jamsite/site-starter-hello-world):

% jamsite start

Open url from output in a browser:

jamsite: Accepting connections on http://127.0.0.1:3000

TODO

  • ✔️ implement frontmatter rewrite rules handling
  • ✔️ implement custom destination file path handling
  • ✔️ impement multifile handling
  • ✔️ setup test system
  • ✔️ support for api and file system routing
  • ✔️ use micro programmatically
  • ✔️ split jamsite and jamsite-dev
  • ✔️ pluggable server middleware (gzip, html minification, etc)
  • ✔️ static templates (dynamic frontmatter, but static page content)
  • ✔️ support toml for data-static files
  • ✔️ windows support
  • ✔️ pluggable core
  • ✔️ support jamsite-config
  • ✔️ task runner
  • ✔️ support .env
  • ✔️ config: error pages, headers, redirects, rewrite, etc.
  • save generated pages as static files
  • i18n concept (locale aware templates, locale aware data)
  • data explorer
  • fix premature ready event in chokidar

Performance

% ./test-performance.sh
Running 40s test @ http://127.0.0.1:3000/hello-world.html
100 connections with 10 pipelining factor

┌─────────┬──────┬──────┬───────┬───────┬─────────┬─────────┬───────────┐
│ Stat    │ 2.5% │ 50%  │ 97.5% │ 99%   │ Avg     │ Stdev   │ Max       │
├─────────┼──────┼──────┼───────┼───────┼─────────┼─────────┼───────────┤
│ Latency │ 0 ms │ 0 ms │ 12 ms │ 13 ms │ 1.22 ms │ 3.67 ms │ 100.33 ms │
└─────────┴──────┴──────┴───────┴───────┴─────────┴─────────┴───────────┘
┌───────────┬─────────┬─────────┬─────────┬─────────┬─────────┬─────────┬─────────┐
│ Stat      │ 1%      │ 2.5%    │ 50%     │ 97.5%   │ Avg     │ Stdev   │ Min     │
├───────────┼─────────┼─────────┼─────────┼─────────┼─────────┼─────────┼─────────┤
│ Req/Sec   │ 61663   │ 61663   │ 79167   │ 79743   │ 78612.4 │ 2769.29 │ 61650   │
├───────────┼─────────┼─────────┼─────────┼─────────┼─────────┼─────────┼─────────┤
│ Bytes/Sec │ 9.44 MB │ 9.44 MB │ 12.1 MB │ 12.2 MB │ 12 MB   │ 424 kB  │ 9.43 MB │
└───────────┴─────────┴─────────┴─────────┴─────────┴─────────┴─────────┴─────────┘

Req/Bytes counts sampled once per second.

3144k requests in 40.05s, 481 MB read

Readme

Keywords

Package Sidebar

Install

npm i @jamsite/jamsite

Weekly Downloads

1

Version

0.0.30

License

MIT

Unpacked Size

226 kB

Total Files

32

Last publish

Collaborators

  • tsertkov