cssinjs / jss

JSS is an authoring tool for CSS which uses JavaScript as a host language.
https://cssinjs.org
MIT License
7.06k stars 397 forks source link

Validation failure: The “type” attribute for the “style” element is not needed and should be omitted #724

Closed mikkopori closed 6 years ago

mikkopori commented 6 years ago

Hello,

testing my application with a validator I ran into these warnings:

The “type” attribute for the “style” element is not needed and should be omitted

for example in

Since I noticed that validation errors were reported here earlier I thought I should report this as well. Did not find any mention of this particular warning.

:)

kof commented 6 years ago

didn't know adding optional type attribtute is an antipattern now

oliviertassinari commented 6 years ago

You can reproduce the warning on your documentation website with https://validator.w3.org/:

capture d ecran 2018-06-10 a 13 09 20

oliviertassinari commented 6 years ago

It should be as simple as removing this line: https://github.com/cssinjs/jss/blob/602e3257d55849bdcf9831d111b029f383951c02/src/renderers/DomRenderer.js#L309 Then, maybe updating the tests and updating the docs. @mikkopori Do you want to work on it?

mikkopori commented 6 years ago

It would be fair since I reported this :)

Never worked on this before, but I guess I'll learn quick. It will take a couple of days before I have time to look into this, so if anyone is faster feel free.

kof commented 6 years ago

released 9.8.6