@gramlot/gramlot-js-server
v0.2.6
Published
Node.js and Bun host adapter for Gramlot JavaScript pages
Readme
@gramlot/gramlot-js-server
Node.js and Bun host adapter for JavaScript Gramlot
pages. It connects a folder of Page modules to the core's FileHost and serves
the bootstrap document, the Source requests, the page modules and stylesheets,
the core themes and the files you list, under a mount prefix of your choice.
npm install @gramlot/gramlot @gramlot/gramlot-js-serverimport {startServer} from '@gramlot/gramlot-js-server/node'; // Bun: '@gramlot/gramlot-js-server/bun'
const app = await startServer({pages: '/path/to/pages', port: 8080});The command gramlot serves the gallery of @gramlot/gramlot-examples
(an optional peer dependency):
npm install @gramlot/gramlot-examples
npx gramlot node gallery # or: npx gramlot bun galleryA new project: npm create @gramlot site my-site. Quick start, guides and
compatibility: the repository README
and the documentation.
Licensed under the Apache License, Version 2.0.
