Commands with a stop method, never programmatically stoped don`t run again!
Hi @lucasschirm and thanks for the report. As you've might notice this is the breaking change we've introduced in the latest version https://github.com/artf/grapesjs/releases/tag/v0.14.55 The reason behind it is quite simple. If you create a command with start and stop command you explicitly declare it as stateful one...
Read full answer below βQuestion
Problem When you add a custom command with stop and dont stop will not run again if I dont set force: 1 as a parameter when running. When you add a custom command with a stop method like: var fired = 0; editor.Commands.add('custom-command', { run() { fired++; console.log("fired ", fired); }, stop() { console.log("Command stoped"); } }); and if never run stop, the run method will never fired again. editor.Commands.run('custom-command'); editor.Commands.run('custom-command'); editor.Commands.stop('custom-command'); editor.Commands.run('custom-command'); should print fired 1 fired 2 stoped fired...
Answers (3)
Hi @lucasschirm and thanks for the report. As you've might notice this is the breaking change we've introduced in the latest version https://github.com/artf/grapesjs/releases/tag/v0.14.55 The reason behind it is quite simple. If you create a command with start and stop command you explicitly declar...
Thank you, I've sended an PR about the modal closing not firing the modal I close trigger. On Thu, Mar 21, 2019, 3:14 PM Artur Arseniev <[email protected]> wrote: Hi @lucasschirm <https://github.com/lucasschirm> and thanks for the report. As you've might notice this is the breaking change we...
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
Related Questions and Answers
Continue research with similar issue discussions.
Issue #930
[Question] Update resizer after asset changed
Hi! I trying to change default assets manager with ours custom manager. On double click the selected image is replaced with a new one with...
Issue #1457
[Question]: Custom asset manager background-image in Style Manager
Hello, i want to use custom Asset Manager i am used this solution, ` var assettarget =''; editor.Commands.add('open-assets', { run(editor,...
Issue #1487
Load from Database
I've got an issue with loading the lory-slider from my mysql db. When i load it back in, the functionality is gone, i cant slide left or ri...
Issue #1831
[Question] How to run command for a block component?
I'd like to do something like this. so once a user drops the test component into the canvas, I'd like to open up asset manager modal where...
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 βRelated tutorials
In-depth guides on the same topic.
Browse Plugin Categories
Jump directly to plugin category pages on the marketplace.