Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug: Can't instantiate two instances of picker with different picker options #756

Open
makotech222 opened this issue Dec 15, 2022 · 4 comments

Comments

@makotech222
Copy link

I'm importing this library with <script> tag. I have two use cases for the picker; One picker has native + custom emojis, while the second picker has just custom emojis.

If I instantiate the first picker, the second picker will also have native emojis, even though the pickerOptions clears the 'data' prop, and vice versa.

I'm instantiating like so:
return new (window as any).EmojiMart.Picker(pickerOptions)

I've ensured that the proper pickerOptions are being passed in each case. All the matters is which one is instantiated first. It seems like something is being cached after first instantiation in the library.

Thanks!

@karthiknmenon
Copy link

@EtienneLem This seems to be a valid issue with the latest version of the picker. Could you please check this out?

@grumpyguava
Copy link

any work arounds on this yet? Also running into this issue

@mahadazad
Copy link

I am also facing the same issue. I need to show different data set on the same page with multiple editors. Can this be solved, please?

@denova
Copy link

denova commented Feb 5, 2024

+1 to the issue. Also cannot get from 3rd to 5th version because of this...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants