Custom JS plugins
Supercharge your Setka posts with custom JS plugins. Implement your content sliders, image popups, accordions, tabs, and many more. Build JS plugins for your content any way you want.
Last updated
Was this helpful?
Supercharge your Setka posts with custom JS plugins. Implement your content sliders, image popups, accordions, tabs, and many more. Build JS plugins for your content any way you want.
Last updated
Was this helpful?
Setka Editor provides various interactive elements to diversify your content and make it more engaging. It includes animations, galleries, hotspots, and footnotes. And we are always happy to add more to the package.
We also understand that you might need to create experiences that are not yet available as Setka's default features. Therefore, we want to give you an option to create your own JavaScript plugins enabling you to implement new custom elements. For interactive examples, visit our .
Custom JS plugins allow you to build your JavaScript-based logic on top of the Setka Editor content. You can create custom plugins that add new interactive components: galleries, content sliders, animated pieces, checklists, anything you could think of.
Basically, any functionality that can be achieved by combining JavaScript and Setka-based HTML is possible.
You build the JavaScript plugin.
Load it to your server or send it to us to load on Setka CDN. The place to store your JS plugin is determined based on your integration type.
The plugin is then loaded to the Setka content pages. These plugin manipulates the content based on your described logic. The processes of launching the plugin on the page and uploading it to Setka CDN (if needed) are described below:
The JS plugin can be connected to the page by adding the corresponding data-*
attribute into an HTML tag, in a form of:
Where:
[vendor_code]
is the vendor code for your plugin.
[plugin_name]
is the plugin name.
[plugin_name@version]
is the plugin version.
For example, adding the data-stk-plugin="stk--content-slider--content-slider@0.5"
attribute will enable the stk/content-slider@v0.5
plugin.
The HTML code that loads the plugin within the grid will look like this:
There are several ways of storing the plugin depending on the Setka Editor integration type.
Please create plugins with attention to code structure. Keep in mind, that plugins may interfere with the Setka Editor itself if built unsafely. Setka Support team would not be able to debug such modifications.
In the message, please:
Specify your company/account name.
Describe the functionality of the plugin.
Attach the JS file of the plugin.
We will verify the JS code of the plugin. If it complies with our requirements, it would be uploaded to your Setka account. Then you would be able to use it in your posts and components. We will reach out to you directly if any fixes or additional information is needed.
Content slider built of stk-grid components.
Add data-stk-plugin="test-01--content-slider--content-slider@0.5"
attribute to any HTML element of the post:
Simple image lightbox.
Add data-stk-plugin="test-01--lightbox--lightbox@0.4"
attribute to any HTML element of the post:
Simple spoiler.
Add data-stk-plugin="test-01--spoiler--spoiler@0.6"
attribute to any HTML element of the post:
The code that includes the plugin can be saved as a . This way your users would be able to quickly add custom interactive elements to the post.
If you are using a custom , you can upload the JS plugin on your own server where Setka Editor is running. This plugin should also be connected to article pages where the custom element is used.
To enable your custom JS plugin for one of the default CMS integrations and/or in the , please contact our support team at with the topic "Custom JS plugin application".