Closed dannylamb closed 3 years ago
Looks like there's no real consensus on how to do this within the Drupal community, with the leading technique involving modifying your site's root composer file. It may be best to hold off for a while until this sorts itself out.
I am looking to update the install location to the standard web/libraries
folder, though, just so we don't have to stick things in web/sites/all/vendor/assets
, which is causing some minor problems in ISLE.
Wound up pulling it from a CDN. Way simpler and still lets us manage the version of the library within the module.
We have been doing this for every JS for more 2 years already and no larger issue on production.
A few notes:
Good to hear you haven't had many problems with it (other than of course if the CDN goes down).
I did a quick googling and found the license to be gpl compatible, but it was hasty. I'll double check that. Thanks for the heads up.
I was involved recently in troubleshooting https://github.com/Islandora-Labs/islandora_usage_stats_charts/issues/28, and the solution was to move the Chart.js Javascript library from a CDN (cloudflare) to a local copy. I never figured out why the CDN version stopped working, but perhaps @bondjimbond can offer some info if he has any. Best guess is that some caching he or his support vendor had implemented interfered, but that's just a guess.
Openseadragon can be installed with npm, so it should be available to composer. We can use this to keep the version of openseadragon consistent and also streamline installation. One less thing...