v0.1.3
More script control!
Before this release, every script tag printed by HUGE/Scripts was using defer
and crossorigin="anonymous"
. While this is a good practice and will be satisfactory for most use cases, it could break some. HUGE/Scripts keeps those as defaults but introduces settings to control them.
Load strategy
User can now choose defer
, async
or none
to omit it.
Crossorigin
User can choose any string or none
to omit the attribute altogether.
Custom Attributes
Any script tag can now sport an infinite number of attributes data-whatever="that"
.
This can be useful to comply with certain libraries or overwrite the type="text/javascript"
attribute pending client accepts GDPR or other privacy toggle.
Check the Wiki's HUGE/Scripts page for more information.
What's Changed
- Allow slice of strings as env/When context by @regisphilibert in #54
- Scripts: Add crossorigin and loading strategy configuration by @regisphilibert in #55
Full Changelog: v0.1.2...v0.1.3