Issue #3461Opened May 17, 2021by ahmedderkaoui0 reactions

Re-render trait on selected component

Question

I know there is a function that can rerender the view of a trait. However, I still don't know how and where to use it.

this.editor.on('component:selected', model => {
      const component = this.editor.getSelected();
      const models = component.get('traits').models;
      // Parsing types
      for(var index in models) {
        if (models[index].attributes.type == 'typeinput') {
          // How to use the view.rerender() function
          console.log(models[index].target.view)
        }
      }
});

Answers (0)

No answers yet.

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...

Browse Plugin Categories

Jump directly to plugin category pages on the marketplace.