Skip to content

TypeScript API / @contentia/vite-plugin / mountLocalApi

Function: mountLocalApi() ​

ts
function mountLocalApi(
   server, 
   repos, 
   options
): void;

Mount Contentia's own JSON:API over repos at ${basePath}/storage, ${basePath}/documents, and ${basePath}/assets. No auth, no CORS — call this only from configureServer.

Parameters ​

ParameterType
serverLocalApiServer
reposContentiaRepositories
options| true | ContentiaLocalApiOptions

Returns ​

void