-
Notifications
You must be signed in to change notification settings - Fork 0
DEPLOYMENT
Each stage is independently shippable — don't wait for the whole list to do stage 1.
- Public repo
codinglombok/LombokTableSheet, Apache-2.0LICENSE, branch protection onmain. -
.github/workflows/ci.yml(included in this scaffold): install → typecheck → test → build on every PR. - Tag releases
vX.Y.Z; GitHub Releases auto-generated from conventional commits / changelog.
npm login
npm publish --access public-
package.jsonalready sets"files","main","types","license": "Apache-2.0". - Use
npm version patch|minor|major+npm publishper release; CI can automate this on tag push.
Nothing to deploy — both CDNs mirror npm automatically once published.
Import the subpaths you need, not dist/index.js. The package barrel
re-exports the XLSX codec, which reaches formats/zip.js and its
import { deflateRawSync } from 'node:zlib'. A browser cannot resolve that
specifier, so importing the barrel makes the entire module graph fail to load —
the page renders nothing, and the only clue is a console error. This is not
hypothetical: it is what broke the Pages demo.
<script type="module">
import { decodeCsv } from 'https://unpkg.com/lomboktablesheet@1.0.1/dist/formats/csv.js';
import { LombokTable } from 'https://unpkg.com/lomboktablesheet@1.0.1/dist/adapters/dom.js';
</script>The size guards in the CSV, JSON and HTML decoders used to call
Buffer.byteLength() — a Node global — and threw "Buffer is not defined" in a
browser even though they import nothing from node:. They now use an internal
utf8ByteLength() helper. scripts/verify-pages-site.mjs walks the reachable
module graph on every Pages build and fails if a node: import or a Node-only
global creeps back in, so this list stays honest.
Browser-safe today: formats/csv.js, formats/json.js, formats/html.js,
adapters/dom.js, adapters/sheet.js, core/model.js, core/formula.js,
core/splitMerge.js, templates/registry.js, i18n/, plugins/, stats/,
engine/. Node-only: formats/zip.js and formats/xlsx.js (which imports it),
and therefore index.js as well.
Bundlers (Vite, webpack, esbuild) are unaffected — they resolve node:zlib
through their own polyfill or externals configuration. Only direct
<script type="module"> loading hits this.
docker/Dockerfile (included) builds a minimal Node image that runs the test suite and
can serve the examples/ folder for a live demo:
docker build -t lomboktablesheet-demo -f docker/Dockerfile .
docker run --rm -p 8080:8080 lomboktablesheet-demoPublish to Docker Hub / GHCR from CI on tagged releases: ghcr.io/codinglombok/lomboktablesheet-demo:X.Y.Z.
The demo build (examples/vanilla) is static HTML/JS — deployable anywhere that serves files:
AWS (S3 + CloudFront)
aws s3 sync ./examples/vanilla s3://your-bucket --delete
aws cloudfront create-invalidation --distribution-id XXXX --paths "/*"Niagahoster / generic shared hosting / VPS
- Build static assets locally (
npm run build+ copydist/andexamples/vanilla/). - Upload via SFTP/FTP to
public_html/(shared hosting) orrsyncto a VPS behind Nginx:
rsync -avz ./examples/vanilla/ user@your-vps:/var/www/lomboktablesheet/- Nginx serves it as static files — no server runtime required for the demo, since the library itself is client-side.
The PHP port already exists at ports/php (Stage 6 of the roadmap is done — core model,
formula engine, CSV/JSON/Markdown codecs, split/merge; 27 PHPUnit tests, verified
byte-identical to the TS core on matching inputs — see ARCHITECTURE.md §8). To publish:
cd ports/php
composer validate
git tag php-vX.Y.Z && git push --tagsSubmit the repo to packagist.org with GitHub webhook auto-sync enabled, so every tag push republishes automatically. Consumers install via:
composer require codinglombok/lomboktablesheetThe Go port already exists at ports/go (34 tests, go vet/gofmt clean, verified
three-way parity with TS and PHP — see ARCHITECTURE.md §8). Go modules don't require a
separate publish step to a registry the way npm/Packagist do — tagging the repo is
enough:
git tag ports/go/v0.1.0
git push --tagsOnce tagged and pushed to a public GitHub repo, the module is installable immediately:
go get github.com/codinglombok/lomboktablesheet-go@v0.1.0pkg.go.dev indexes it automatically on first fetch (no submission step, unlike
Packagist) — though the first go get from anywhere can take a few minutes to appear.
Not a deploy target in the infra sense — this means: submit the docs site to Google Search
Console, add JSON-LD SoftwareSourceCode structured data to the docs homepage, and list on
relevant package directories (npm's own search already indexes to Google). No separate action
beyond good SEO metadata in README.md/docs site <head>.
Kept in examples/:
-
examples/vanilla/— plain<script type="module">usage. - React/Vue usage — the adapters are done (
lomboktablesheet/react,lomboktablesheet/vue, see README.md's Framework adapters section for usage snippets); a dedicatedexamples/react/andexamples/vue/demo app is a nice-to-have, not yet built as a standalone example. - Go consumption — done:
go get github.com/codinglombok/lomboktablesheet-go(seeports/go/README.md). - Rust consumption — not yet available; once that port exists:
cargo add lomboktablesheet(crates.io) with an optionalwasmfeature flag for web use.
-
npm run typecheck && npm testgreen in CI. - Bump version (
npm version …), updateCHANGELOG.md. -
npm publish. - Tag pushed → GitHub Release notes generated.
- Docker demo image rebuilt and pushed (CI).
- Static demo re-synced to S3/CloudFront and/or VPS if the demo changed.