Installation
npm install datacat-cms
Requirements
VueJS 2.x
Add this code to these files
build/build.js
const indexer = indexerindexer
src/main.js
And to load content for displaying:
storestore
App.vue
Replace #app
with:
#app(v-if='$route.path.indexOf("/admin") !== 0')
index.html
below the app tag.
router/index.js
path: '/admin' { if frommatchedlength > 0 // experimental fix for multi routers return location }
Before your 404 route. This is experimental for now.
Content
Add a content
folder to your project root.
Inside this new folder, add config.json
with these defaults:
And since we have now defined a content type named blogpost
, add a blogpost
folder inside the content
folder. Here is an example for it:
overviewShow
means that the specified field will be used in the overview list preview.
And to prevent _content.json
and _files.json
to get added to git, .gitignore them:
content/_content.json
content/_files.json
VueX
To use the content, add the datacat client module to your VueX instance:
import content from 'datacat-cms/client'
Auth0
Datacat uses auth0 for authentication. You must set your domain and client id in the config/settings.json
file:
# Improvements So yea obviously this is alot of work, but this is a very early version of this system.