Multiple same mod on a page


#1

I take it since mods are inserted with IDs that we’re not able to use the same mod multiple times on a page?


#2

No you can, go bananas :banana:


#3

Awesome :tada:

Is it possible to add data attributes to the mod embed <div> and access those within the mod JS?


#4

Yes, e.g. <div id="anymod-klaln" data-my-field="foo"></div>

Would be accessible in your mod’s JS as mod.myField