Issue #3037💬 AnsweredOpened September 22, 2020by PineTreeWild0 reactions

Get property value by component:styleUpdate event

快速解答by artf

You can take the value directly from the component comp.getStyle()[prop]

Read full answer below ↓

Question

The Changed property name can only be got in component:styleUpdate event, but I cannot get the value of the property.

editor.on('component:styleUpdate', (comp, prop) => { // prop is the updated property name })

Thanks

Answers (1)

artfOctober 1, 2020

You can take the value directly from the component comp.getStyle()[prop]

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 →

Browse Plugin Categories

Jump directly to plugin category pages on the marketplace.