Issue #2459Opened December 18, 2019by kickbk1 reactions

Grapesjs adds "-2" to ids in the html with localStorage

Question

I tried to reproduce this on your demo and could not, yet I am having the strangest issue. I was hoping you could point me in the right direction when debugging this.

As soon as I store the html in localStorage and refresh the page (you will see a short pause in the screencast), grapesjs magically adds "-2" to every id in the html. See screencast below:

grapesjs_adding_dash

Can you think where in your code this might be happening and why? How do I avoid this?

Thanks @artf

Answers (3)

artfDecember 20, 20190 reactions

Do you use the latest version?

kickbkDecember 20, 20190 reactions

@artf, yes I do. 0.15.9, although it's the same with prior versions. I tried to remove all the plugins to keep it all very clean, but still getting this as soon as localStorage is generated. Any ideas why or where this may get generated so I can debug?

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.