Lightweight SolidOS shim with data island support
npm install solidos-liteLightweight SolidOS shim with data island support.
solidos-lite lets you embed RDF data directly in HTML and render it with SolidOS - no server required. Just one script tag:
``html`
It automatically:
- Loads mashlib from CDN
- Parses embedded Turtle or JSON-LD data islands
- Renders with SolidOS panes
`html`
That's it! Visit page.html#me to see Alice's profile.
`html`
`html`
1. Auto-detection - When the page loads, solidos-lite checks for data islands
2. Loads mashlib - Dynamically loads mashlib + CSS from CDN
3. Creates UI - Adds required DOM elements to body automatically
4. Parses data - Turtle parsed directly, JSON-LD converted to Turtle (custom parser, no webpack chunks)
5. Renders - Navigates to the URL fragment (e.g., #me) or shows document view
For manual control:
`javascript
// Run everything automatically
SolidOSLite.run()
// Or step by step:
await SolidOSLite.loadMashlib()
SolidOSLite.init({ verbose: true })
SolidOSLite.parseAllIslands()
`
Initialize and run the data browser. Called automatically if data island detected.
Load mashlib from CDN. Returns a Promise.
Initialize the data island shim. Options: { verbose: true }` for logging.
Parse all data islands into the RDF store.
Current version string.
- Person Profile (JSON-LD) - foaf:Person with photo and connections
- Bookmarks (Turtle) - Organized link collection
- minimal.html - Minimal Turtle example
- minimal-jsonld.html - Minimal JSON-LD example
- Zero boilerplate - Just data + script tag, UI created automatically
- No CORS issues - Data is in the page
- No server required - Works with static HTML files
- Works offline - Once loaded, no network needed
- Single script - Mashlib loaded automatically from CDN
AGPL-3.0