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

Improve documentation website #8

Merged
merged 3 commits into from
Nov 28, 2023
Merged

Improve documentation website #8

merged 3 commits into from
Nov 28, 2023

Conversation

nmn
Copy link
Contributor

@nmn nmn commented Nov 27, 2023

Made the following improvements:

  1. Added a new section to the home page with a quick overview of the top stylex features
  2. Created an "Introduction" page and moved appropriate content from other pages to it
  3. Improved "Installation" page
  4. "Get Started" link on Home page now goes to the "Installation" page
  5. Replaced "Learn" CTA with an "API Reference" CTA.

Preview Link: https://stylex-docusaurus-11zzqvnrr-nmn.vercel.app

@facebook-github-bot facebook-github-bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Nov 27, 2023
@nmn nmn requested review from necolas, elicwhite and Jta26 November 27, 2023 11:56
Copy link

compressed-size: runtime library

Size change: 0.00 kB
Total size: 2.36 kB

View unchanged
Filename: gzip (minify) kB size kB change % change
./packages/stylex/lib/stylex.js 1.02 (3.53) 0.00 (0.00) 0.0% (0.0%)
./packages/stylex/lib/StyleXSheet.js 1.34 (3.41) 0.00 (0.00) 0.0% (0.0%)

Copy link

compressed-size: e2e bundles

Size change: 0.00 kB
Total size: 1119.39 kB

View unchanged
Filename: gzip (minify) kB size kB change % change
./apps/rollup-example/.build/bundle.js 1005.22 (9872.52) 0.00 (0.00) 0.0% (0.0%)
./apps/rollup-example/.build/stylex.css 114.18 (455.95) 0.00 (0.00) 0.0% (0.0%)

apps/docs/components/FeatureCard.js Outdated Show resolved Hide resolved
apps/docs/components/FeatureCard.js Outdated Show resolved Hide resolved
apps/docs/docs/learn/01-installation.mdx Outdated Show resolved Hide resolved
apps/docs/docs/learn/01-introduction/01-Introduction.mdx Outdated Show resolved Hide resolved
apps/docs/docs/learn/01-introduction/01-Introduction.mdx Outdated Show resolved Hide resolved
apps/docs/src/pages/index.js Outdated Show resolved Hide resolved
apps/docs/src/pages/index.js Outdated Show resolved Hide resolved
apps/docs/src/pages/index.js Outdated Show resolved Hide resolved
apps/docs/src/pages/index.js Outdated Show resolved Hide resolved
apps/docs/src/pages/index.js Outdated Show resolved Hide resolved
@necolas
Copy link
Contributor

necolas commented Nov 27, 2023

More changes to "Thinking in StyleX"

  1. Update "And the stylex() or stylex.props() calls are executed at runtime." to remove mention of stylex()

  2. Update "StyleX disallows this entire class of selectors. This currently makes some patterns in CSS impossible: e.g. It is currently impossible for a child element to have conditional styles when it's parent is hovered. Our goal is to support these patterns without sacrificing style encapsulation." It's technically possible using CSS vars as tokens. We should keep "Our goal is to support ...without sacrificing style encapsulation. For example, child elements cna be conditionally styled when a parent is hovered by..."

  3. Recommend removing this entirely: "Tailwind CSS is popular and lets you author your styles by putting extremely terse utility class names directly on your markup. This is great for authoring styles quickly, but in our opinion, in the long run, it makes the styles harder to read and maintain. It can also have a steeper learning curve up-front."

@nmn
Copy link
Contributor Author

nmn commented Nov 27, 2023

@nmn nmn requested a review from necolas November 27, 2023 20:57
Comment on lines 320 to 321
patterns in CSS impossible: e.g. It is currently impossible for a child element
to have conditional styles when it's parent is hovered.
Copy link
Contributor

Choose a reason for hiding this comment

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

Shouldn't this be removed since below we describe how child elements can have conditional styles when parents are hovered - using variables

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I'm going to make this simpler and more vague.

Copy link
Contributor

@necolas necolas left a comment

Choose a reason for hiding this comment

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

A couple more minor issues. I think the <details> rendering that you're using to collapse bundler examples doesn't look great right now. And the options shown for each of the bundlers are different.

Also noticed a few "bad patterns" in the CSS for the docs themselves, which brings up the question of what is still supported in the OSS release.

Copy link
Contributor

@necolas necolas left a comment

Choose a reason for hiding this comment

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

Approving to unblock as it's basically there!

@nmn
Copy link
Contributor Author

nmn commented Nov 28, 2023

@nmn nmn merged commit 596234d into main Nov 28, 2023
7 checks passed
@nmn nmn deleted the website-home branch November 28, 2023 07:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants