Commit a7cd412
fix: stop overriding Rails' media default in vite_javascript_tag (#610)
* fix: remove hardcoded media: "screen" default from vite_javascript_tag
vite_javascript_tag was explicitly passing media: "screen" to
stylesheet_link_tag, overriding Rails' own apply_stylesheet_media_default
setting. Users who opt out of the legacy media default (by setting
apply_stylesheet_media_default = false) were still getting media="screen"
on stylesheet link tags generated by vite_javascript_tag.
Changing the default to nil defers to stylesheet_link_tag's own behavior:
when apply_stylesheet_media_default is true (Rails default), it still adds
media="screen"; when it's false, no media attribute is rendered. Callers
who need a specific value can still pass media: "screen" (or any other
value) explicitly.
Fixes #535
* chore: revert change to legacy gem
---------
Co-authored-by: Ernane <ernane@seguroviagem.srv.br>
Co-authored-by: Maximo Mussini <maximomussini@gmail.com>1 parent c6cf52a commit a7cd412
1 file changed
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
41 | 41 | | |
42 | 42 | | |
43 | 43 | | |
44 | | - | |
| 44 | + | |
45 | 45 | | |
46 | 46 | | |
47 | 47 | | |
| |||
0 commit comments