Plugin ideas #108
Replies: 5 comments
-
|
|
Beta Was this translation helpful? Give feedback.
-
|
Thinking about adding a set of core plugins to this repo for easier maintenance. Core plugins should be the ones that you won't want to use NotionCMS without 9/10 times. Here are the ones I'm thinking:
For instance, if you have images in your Notion content at all you will want to cache them. Just makes sense to keep these plugins closer to core, everything else is extra and promotes community plugins. |
Beta Was this translation helpful? Give feedback.
-
|
Here's one: tabs with code in different languages or examples. Could be done using a callout containing several codeblocks in different langs, the lang will be rendered as the tab title. |
Beta Was this translation helpful? Give feedback.
-
|
Sometimes you want the content of the page to be translated into a collection in the CMS. For instance I have a page that I use in notion to keep track of some unit of things that I like or links, micro blog posts, etc. It would be nice to convert this to a collection. This could be done using a plugin. |
Beta Was this translation helpful? Give feedback.
-
|
For search implementation, see https://github.com/agency-kit/agencykit-rag-api-starter. It uses Lunr JS to index content pulled from Notion using NotionCMS |
Beta Was this translation helpful? Give feedback.

Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
A plugin exist to extend NotionCMS in some way. There are currently only two hooks where the plugins run but long term I think we should provide hooks at these points:
post-db-call,pre-parse,post-parse,final.Right now pre and post parsing just give you access to the blocks or html for an individual entry so we should add a hook
post-db-call(working title) for pre processing the tree-level pre-content calls (in factpre-contentmight be a good name) and afinalorpost-contenthook for any final tree-level transforms. This opens up many more possibilities for what a plugin can do.The main idea of plugins is that the core database that comes with NotionCMS is as minimal as possible. Whenever you add a plugin you can add data properties that you expect to see for each entry.
As such plugins should come with necessary template or schema for the notion database so that they are easy for users to consume. NotionCMS should provide plugin types and the plugin itself should update type expectations for the tree structure should it modify the tree in any way.
Here's the list of planned plugins:
vue-substrat-forms.tsfor working example.Some import workflow improvements (see #30) :
Some loftier ones:
Some plugin helpers we need to expose:
Beta Was this translation helpful? Give feedback.
All reactions