Skip to content

Rails importmap pin tom-select pulled wrong version? #830

Answered by maxim
silent-e asked this question in Q&A
Discussion options

You must be logged in to vote

For anyone coming here, you can get the file like this:

bin/importmap pin tom-select/dist/js/tom-select.complete.min.js
mv vendor/javascript/tom-select--dist--js--tom-select.complete.min.js.js vendor/javascript/tom-select.js

and then in importmap.rb

pin "tom-select" # @2.4.1

This seems to bundle tom-select, sifter, unicode-variants and all the plugins. And this line import TomSelect from "tom-select" seems to work.

P.S. So far I've discovered everything like the above by trial and error. I posted some questions trying to understand the pin urls better, but at the time of this writing haven't gotten any answers.

P.P.S. Every pin in my importmap.rb comes with a big comment above it, explai…

Replies: 2 comments 1 reply

Comment options

You must be logged in to vote
1 reply
@silent-e
Comment options

Answer selected by silent-e
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants