Skip to content

New ids after fromJSON #1841

Answered by kumilingus
adalekin asked this question in Q&A
Oct 14, 2022 · 1 comments · 1 reply
Discussion options

You must be logged in to vote

I think I have seen this before. There is nothing wrong with the JSON or the fromJSON() graph method.

When you create a custom shape by extending a class and you override the initialize method (or similar) make sure to pass all the arguments to super.

class Shape extends dia.Element {
  initialize(...args) {
     super(...args);
     /* your code */
  }
}

Is it the case?

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@adalekin
Comment options

Answer selected by adalekin
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants