Issue #629Opened December 11, 2017by krunal0390 reactions

traits sometime does not fire event

Question

sometime traits change event does not fire event on model and view and I have seen below error for that.

Uncaught RangeError: Maximum call stack size exceeded. at HTMLDivElement.<anonymous> (grapes.min.js:9229) at o (grapes.min.js:8871) at i.each (grapes.min.js:9131) at i.trigger (grapes.min.js:9228) at i.o.trigger (grapes.min.js:23251) at i.o.click (grapes.min.js:23274) at F.i.openSettings (grapesjs-hsbc.js:1232) at HTMLDivElement.<anonymous> (grapes.min.js:9229) at o (grapes.min.js:8871) at i.each (grapes.min.js:9131)

Answers (3)

artfDecember 13, 20170 reactions

@krunal039 about what event are you talking about? Can you provide at least an example of how reproduce it

krunal039December 14, 20170 reactions

@artf below is codepen link and i have added custom component named slider. here when you drop slider to editor and than click on it and it should open trait manager and if you change Link Title or Link to Open to blank value it throws above error.

https://codepen.io/kmpdev/full/LORdOM/

error:

Uncaught RangeError: Maximum call stack size exceeded. 2grapes.min.js:2 Uncaught RangeError: Maximum call stack size exceeded. at HTMLDivElement.<anonymous> (https://cdnjs.cloudflare.com/ajax/libs/grapesjs/0.12.25/grapes.min.js:2:232013) at o (https://cdnjs.cloudflare.com/ajax/libs/grapesjs/0.12.25/grapes.min.js:2:225570) at i.each (https://cdnjs.cloudflare.com/ajax/libs/grapesjs/0.12.25/grapes.min.js:2:230006) at i.trigger (https://cdnjs.cloudflare.com/ajax/libs/grapesjs/0.12.25/grapes.min.js:2:231987) at i.o.trigger (https://cdnjs.cloudflare.com/ajax/libs/grapesjs/0.12.25/grapes.min.js:11:29611) at i.o.click (https://cdnjs.cloudflare.com/ajax/libs/grapesjs/0.12.25/grapes.min.js:11:30120) at i.openSettings (pen.js:1921:20) at HTMLDivElement.<anonymous> (https://cdnjs.cloudflare.com/ajax/libs/grapesjs/0.12.25/grapes.min.js:2:232013) at o (https://cdnjs.cloudflare.com/ajax/libs/grapesjs/0.12.25/grapes.min.js:2:225570) at i.each (https://cdnjs.cloudflare.com/ajax/libs/grapesjs/0.12.25/grapes.min.js:2:230006)

artfDecember 14, 20170 reactions

I can't reproduce any error, but what I see wrong at the first look is how you update models

...
someModel.attributes.href = this.get("a_href");
// use
someModel.set('href', this.get("a_href"));

then you don't need $(this.el), you have already this.$el

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.