-
Notifications
You must be signed in to change notification settings - Fork 144
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Possibility to specify type attribute #163
base: main
Are you sure you want to change the base?
Conversation
Now it will be possible to specify or type attribute of <style>
Codecov Report
@@ Coverage Diff @@
## master #163 +/- ##
==========================================
+ Coverage 80.95% 81.25% +0.29%
==========================================
Files 4 4
Lines 63 64 +1
Branches 15 17 +2
==========================================
+ Hits 51 52 +1
Misses 11 11
Partials 1 1
Continue to review full report at Codecov.
|
Why not just remove this line at all? isomorphic-style-loader/src/insertCss.js Line 69 in a990d94
|
For backward compatibility at least |
@frenzzy Any news on this PR? |
@BilyachenkoOY sorry, I am not interested in maintenance |
@koistya can you help with this? :) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a minor change regarding the code format. Please add at least one test for this in order to allow future maintenance
if (type === undefined || typeof type === 'string') | ||
elem.setAttribute('type', type || 'text/css') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if (type === undefined || typeof type === 'string') | |
elem.setAttribute('type', type || 'text/css') | |
if (!type || typeof type === 'string') { | |
elem.setAttribute('type', type || 'text/css') | |
} |
Now it will be possible to specify type attribute of <style>.
This will allow to fix warning from W3C validator "The type attribute for the style element is not needed and should be omitted.".