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

docs(examples): add Material UI example #1441

Closed
wants to merge 6 commits into from

Conversation

Anishpras
Copy link
Contributor

No description provided.

Copy link
Member

@kentcdodds kentcdodds left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great to me 👍 Just a couple changes needed.

examples/material-ui/README.md Outdated Show resolved Hide resolved

// Add the emotion style tags after the insertion point meta tag
const markup = html.replace(
/<meta(\s)*name="emotion-insertion-point"(\s)*content="emotion-insertion-point"(\s)*\/>/,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this could be much simpler if this were something like __STYLES__ (like the styled-components example).

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@kentcdodds I think it is correct because in the styled-components example the STYLES was replaced from the extracted CSS and in material-UI, we need to add the emotion style tags after the insertion point meta tags and this is a one-time thing as shown in the official material-UI examples.

@@ -0,0 +1,53 @@
# Material-UI Example
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This README doesn’t follow the other examples style, for example it doesn’t have a button to try it in CodeSandbox

examples/material-ui/app/root.tsx Outdated Show resolved Hide resolved
@kentcdodds
Copy link
Member

I think you may need to apply the same strategy that's done in #1485 to avoid some pit-falls with CSS-in-JS. Can you give that a look?

@kentcdodds kentcdodds added the needs-response We need a response from the original author about this issue/PR label Mar 7, 2022
@MichaelDeBoey MichaelDeBoey changed the title Material UI example docs(examples): add Material UI example Mar 18, 2022
@chaance chaance closed this Apr 29, 2022
@MichaelDeBoey MichaelDeBoey removed the needs-response We need a response from the original author about this issue/PR label May 1, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants