Skip to content
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

[examples] Fix HTML end tag #15293

Merged
merged 2 commits into from Apr 10, 2019
Merged

[examples] Fix HTML end tag #15293

merged 2 commits into from Apr 10, 2019

Conversation

raybooysen
Copy link
Contributor

@raybooysen raybooysen commented Apr 10, 2019

@mui-pr-bot
Copy link

mui-pr-bot commented Apr 10, 2019

Details of bundle changes.

Comparing: 784c0a2...c2eff6a

bundle parsed diff gzip diff prev parsed current parsed prev gzip current gzip
@material-ui/core 0.00% 0.00% 347,568 347,568 89,893 89,893
@material-ui/core/Paper 0.00% 0.00% 68,404 68,404 20,053 20,053
@material-ui/core/Paper.esm 0.00% 0.00% 60,735 60,735 18,785 18,785
@material-ui/core/Popper 0.00% 0.00% 34,930 34,930 11,917 11,917
@material-ui/core/styles/createMuiTheme 0.00% 0.00% 17,877 17,877 5,962 5,962
@material-ui/core/useMediaQuery 0.00% 0.00% 2,463 2,463 1,044 1,044
@material-ui/lab 0.00% 0.00% 148,119 148,119 43,913 43,913
@material-ui/styles 0.00% 0.00% 53,143 53,143 15,443 15,443
@material-ui/system 0.00% 0.00% 17,132 17,132 4,519 4,519
Button 0.00% 0.00% 88,669 88,669 26,423 26,423
Modal 0.00% 0.00% 82,688 82,688 24,802 24,802
colorManipulator 0.00% 0.00% 3,745 3,745 1,537 1,537
docs.landing 0.00% +0.02% 🔺 49,820 49,822 10,807 10,809
docs.main 0.00% 0.00% 644,630 644,634 200,877 200,879
packages/material-ui/build/umd/material-ui.production.min.js 0.00% 0.00% 296,257 296,257 82,811 82,811

Generated by 🚫 dangerJS against c2eff6a

@travikk

This comment has been minimized.

@oliviertassinari oliviertassinari changed the title Minor fix to close tag properly [examples] Fix HTML end tag Apr 10, 2019
@oliviertassinari
Copy link
Member

oliviertassinari commented Apr 10, 2019

The correct version is:

<link rel="stylesheet" href="https://fonts.googleapis.com/icon?family=Material+Icons">

We should fix the other links. https://www.w3.org/TR/html5/document-metadata.html#the-link-element

Capture d’écran 2019-04-10 à 10 19 09

@oliviertassinari
Copy link
Member

create react app used to do it correctly before: facebook/create-react-app#5839.

@eps1lon
Copy link
Member

eps1lon commented Apr 10, 2019

  • self closing void elements (Content Model: nothing) are valid html5

Then, if the element is one of the void elements, or if the element is a foreign element, then there may be a single U+002F SOLIDUS character (/). This character has no effect on void elements, but on foreign elements it marks the start tag as self-closing.

--https://www.w3.org/TR/html5/syntax.html#start-tags

  • prettier formats it that way
  • it's closer to react
  • matches our current approach

@oliviertassinari
Copy link
Member

oliviertassinari commented Apr 10, 2019

Well, I have looked at Amazon & Facebook HTML response from the server they add a leading /> (Google doesn't). I guess we can follow them. It will soften the different between HTML and JSX

@oliviertassinari oliviertassinari self-assigned this Apr 10, 2019
@oliviertassinari oliviertassinari removed their assignment Apr 10, 2019
@oliviertassinari oliviertassinari added PR: good for merge docs Improvements or additions to the documentation labels Apr 10, 2019
@oliviertassinari oliviertassinari merged commit 7fce44a into mui:next Apr 10, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Improvements or additions to the documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants