Update Traits properties on a plugin
Question
Hi,
is it possible to change easily some properties in the Traits configuration of a plugin ? I"m trying to translate some strings in the grapesjs-echarts plugin, and i kindy stucked after reading your documentation and looking for the functions to do so...
Could please tell me if it's possible to change some options plugins when it's not implemented by default ?
Regards
Answers (3)
You should be able to do it via i18n module
editor.I18n.addMessages({
en: {
traitManager: {
labels: {
title: 'My Title', // `title` is the name of the trait
}
},
}
});
Hi, thank you for the answer. I agree with you, it changes indeed the default labels on Traits (. But what about a plugin, or a component not added in the i18n module ? For example, the type "map" include in your initial javascript, how can i update without override your plugin it's properties defi...
Hi again,
any idea to help me to update traits default properties after the plugin initialization ? In my previous sampe, i have a hard coded type 'map' in my grapes.js , i would like to update some traits properties in my html page with some translation and custom values.
Best regards
Related Questions and Answers
Continue research with similar issue discussions.
Issue #4371
All editors broken after last update that broke storage manager.
GrapesJS version [X] I confirm to use the latest version of GrapesJS What browser are you using? Chrome Reproducible demo link https://www....
Issue #2337
[BUG / QUESTION] Deleting default styles does not work
Hello, i'm trying to delete some of the default styles of the blocks. I wrote everything I changed in a plugin. I used this function to upd...
Issue #3400
Ckeditor5 + GrapesJS now is possible!
We are DevFuture, we developed plugin for integrate GrapesJS + ckeditor5. Video example: https://www.youtube.com/watch?v=xn4gSMIrx-A We kno...
Issue #3170
Add class name from traits
Hello, what i am trying to achieve is to have the text component extended by assigning an extra trait named Alignment and deciding through...
Paid Plugins That Match This Issue
Curated by issue keywords and label relevance to help you ship faster.
Loading paid plugin recommendations...
Check the open-source GrapesJS plugins on GitHub or run a quick search in our free catalog.
Browse free plugins →Premium plugins ship with support, regular updates, and production-ready features — save days of integration work.
Browse premium plugins →Browse Plugin Categories
Jump directly to plugin category pages on the marketplace.