← @mortar-kit/core/server

createJsonFileStorefunction

import { createJsonFileStore } from '@mortar-kit/core/server'

function createJsonFileStore(options: JsonFileStoreOptions): ContentStore

A content store backed by JSON files. Collection names and slugs are checked, so neither can escape dir. A file that can't be parsed is skipped when listing (and logged), so one bad file doesn't break every list on the site, but reading it directly throws.

Parameters

Returns

ContentStore