There should be a warning for duplicate IDs

This snippet tries to instantiate two Datatables with the same ID, then fails silently to render one of them. It would be useful to generate an error if duplicate IDs are detected.

In this particular case, the error may be obvious, but when using Multiviews, it's much easier to reuse IDs in hidden views and not realize why data isn't parsed.

Tagged:

Comments

  • edited August 2018

    Such warning message is generated in the debug mode which is recommended for use while developing. Non-unique ids do not immediately break the app, that's why the production version doesn't fail in this case.

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion