Choices-js / Choices

A vanilla JS customisable select box/text input plugin ⚡️
https://choices-js.github.io/Choices/
MIT License
6.06k stars 598 forks source link

Object object when using custom data on select #1085

Open joseehilton147 opened 1 year ago

joseehilton147 commented 1 year ago

When passing custom data like image bellow: image

On HTML is returning object object: image

How can I retrieve this data-custom-properties on javaScript function? I need that value to make my code working, for now I'm passing all values into an object on value, a bit wrong but works.

julienbfabre commented 1 year ago

When passing custom data like image bellow: image

On HTML is returning object object: image

How can I retrieve this data-custom-properties on javaScript function? I need that value to make my code working, for now I'm passing all values into an object on value, a bit wrong but works.

did you figure this out?

joseehilton147 commented 1 year ago

When passing custom data like image bellow: image On HTML is returning object object: image How can I retrieve this data-custom-properties on javaScript function? I need that value to make my code working, for now I'm passing all values into an object on value, a bit wrong but works.

did you figure this out?

No