@offmadisonave/oma-keystone-cms

1.0.17 • Public • Published

OMA Keystone CMS

Our Keystone CMS "plug-in" provides very basic contextual editing features such as object model property editing and a simple templated page system. It is dependent on use of Keystone using the Swig templating engine. The contextual front end UI is currently written in AngularJS. It is a work in progress that is not intended for public use, but is nonetheless published as a public package for our own purposes. Use at your own risk.

Installation Instructions

  • In your Keystone project:
npm install @offmadisonave/oma-keystone-cms --save
  • Add the following code to the top of the Keystone project /routes/index.js module body
require('@offmadisonave/oma-keystone-cms')(app, {
	indexIsPage: true // If you intend to use the pages feature at the default route
});
  • Add the following just before the closing body tag of all of your Keystone project layout SWIG files...
{{CMS.admin()}}
  • To make a model object editable...
{{CMS.objectHtml('KeystoneListName', listObject, 'editablePropertyName')}}

If you intend to use the pages feature:

  • Create at least one SWIG template that you intend to use for the CMS and register it in the Keystone Admin UI at http://{yourdomain.com}/keystone/cmstemplates

  • To make a page block editable...

{{CMS.pageHtml('content_block_name')}}

Creating a page is as simple as navigating to /page/{the_slug_you_want} and clicking the Create Page in the CMS footer toolbar.

Readme

Keywords

none

Package Sidebar

Install

npm i @offmadisonave/oma-keystone-cms

Weekly Downloads

0

Version

1.0.17

License

MIT

Last publish

Collaborators

  • offmadisonave