Issue #1837πŸ’¬ AnsweredOpened February 26, 2019by SeongwoonHong0 reactions

How to change the label of traits?

Quick answerby NicoEngler

You just need to define the label! :)

Read full answer below ↓

Question

I'd like change the labels of triats which are going to be french.

capture

Could you give a piece of example code? Thank you Artur

Answers (3)

NicoEnglerβ€’ February 27, 2019

You just need to define the label! :)

          traits: [{
            type: 'text',
            label: 'Title',
            name: 'title',
            placeholder: 'Lorem ipsum',
            changeProp: 1
          }]
SeongwoonHongβ€’ February 27, 2019

@NicoEngler Hi Thank you for reply! but I'm trying to modify existing built in traits. i'm not trying to create custom traits..

NicoEnglerβ€’ February 28, 2019

From what I have observed, you cannot define a label for the built in traits. Also the name (with uppercase(0)) is used if a label is undefined. That's why I guess your best bet is to define your traits along with proper label. Or better, write a PR for this. πŸ‘

I may be wrong on this, maybe Artur can eloborate further.

Related Questions and Answers

Continue research with similar issue discussions.

Paid Plugins That Match This Issue

Curated by issue keywords and label relevance to help you ship faster.

View all plugins

Loading paid plugin recommendations...

Free option

Check the open-source GrapesJS plugins on GitHub or run a quick search in our free catalog.

Browse free plugins β†’
Premium option

Premium plugins ship with support, regular updates, and production-ready features β€” save days of integration work.

Browse premium plugins β†’

Related tutorials

In-depth guides on the same topic.

All tutorials β†’

Browse Plugin Categories

Jump directly to plugin category pages on the marketplace.