lekoala/bootstrap5-tags

Question: Specify single select field with an ID

scath999 opened this issue · 3 comments

I can't seem to find any documentation on how to specify which select(s) I'd like this library to interact with.

I have multiple select forms on a page, but don't want bootstrap5-tags to alter all of them (which is what's happening out-of-the-box).

Any guidance on how to accomplish this would be very welcome.

NOTE: I'm using including this with a <script> tag on the pages that require it, and am using Flask not React.

Tags.init takes any selector you want. if you have a specific class like .tags-input you can use Tags.init('.tags-input')
or you can use new Tags(el) where el is the select element

closing this, feel free to reopen if any other question

Apologies - I got caught up with a bunch of things at work, but yes, this works well. Much appreciated!