A React + Vite app using React Flow to explore and visualize OSDU JSON Schemas and their relationships.
Check out the live demo here.
Quick features
- Dropdown search to find and select any schema found under
public/data/**/*.(min.)json. The current schema source is from the publishedv0.28.7here and reference values here. - Fast text search / filter by schema title, $id or version.
- Clickable graph nodes with styled relationship edges and tooltip details.
- Tooltip shows properties, relationships and (for reference-data types) loads reference values from disk.
- Node.js 18 or later
- npm (or yarn) — project uses npm scripts
- Modern browser for the UI (Chrome, Edge, Firefox) with IndexedDB support
- Recommended: 4+ GB free disk and 2+ GB RAM for a smooth dev experience when working with all schemas
- Clone the repo and change into the project directory:
git clone <repo> && cd osdu-viz- Install dependencies:
npm install- Run the dev server (Vite):
npm run dev- Open the app in your browser (usually
http://localhost:5173)
- The app prefers minified JSON assets in
public/data(*.min.json). The build script scanspublic/data/Generatedand writespublic/schema-index.jsonwhich the app consumes at runtime. - If you host the app under a subpath, set Vite's
base(for examplebase: '/osdu-viz/'invite.config.ts). The app uses the ViteBASE_URLinternally so asset fetches resolve correctly. - Serve
dist/(thenpm run buildoutput) from a static host or CDN. Configure long-lived caching for versioned.min.jsonfiles and appropriate cache-control forschema-index.json.
- DB name:
osdu-viz-cache - Object store:
schemas(keyPath:path) - Behavior: cached schemas are only used as a fallback when network fetches return zero schemas (offline resume). This avoids merging large cached sets into fresh loads.
- If reference values are not visible in tooltips, check the Network tab for attempted candidate paths like
/data/reference-data/OPEN/RigType.1.min.json. - To inspect the IndexedDB cache in Chrome: DevTools → Application → IndexedDB →
osdu-viz-cache→schemas.
Development
- Requires Node 18+
Run locally
npm install
npm run devBuild
npm run build
npm run previewTests
npm test