projectblacklight / arclight

A Rails engine supporting discovery of archival material
https://samvera.atlassian.net/wiki/spaces/samvera/pages/405211890/ArcLight
Other
39 stars 25 forks source link

UI doesn't work unless browser supports importmaps #1529

Open seanaery opened 6 months ago

seanaery commented 6 months ago

As of January 2024, an ArcLight application with updated gem dependencies (esp. importmap-rails v2+) will no longer work in browsers that don't natively support Import Maps. This might also be applicable to the Blacklight core engine.

According to https://caniuse.com/import-maps, that'd be about 8.5% of browsers, especially including:

Screenshot (Demo ArcLight)

This shows the Contents unable to load (and related console error) on Demo ArcLight w/Firefox 107:

Screenshot 2024-04-24 at 9 56 38 AM

Explanation

The importmap-rails gem dropped its inclusion of the es-module-shim in version 2.0 (Jan 2024); the shim enabled importmaps to work on older browsers. Per this README (which also confirms that the console error above is caused by this shim not being present), you can manually add it back in.