Repository navigation
feat: new lint rule to enforce stylex file extension - #704
Merged
Merged
Conversation
mellyeliu
force-pushed
the
enforce-stylex-extension
branch
2 times, most recently
from
October 1, 2024 07:21
0786e46 to
3f44a85
Compare
mellyeliu
force-pushed
the
enforce-stylex-extension
branch
from
October 1, 2024 07:45
3f44a85 to
5c25d14
Compare
workflow: benchmarks/sizeComparison of minified (terser) and compressed (brotli) size results, measured in bytes. Smaller is better.
|
mellyeliu
force-pushed
the
enforce-stylex-extension
branch
from
October 1, 2024 17:41
5c25d14 to
d126761
Compare
nmn
requested changes
Oct 1, 2024
nmn
reviewed
Oct 1, 2024
nmn
requested changes
Oct 1, 2024
nmn
left a comment
Collaborator
There was a problem hiding this comment.
You missed Default Exports. Default exports should be treated all other exports.
mellyeliu
force-pushed
the
enforce-stylex-extension
branch
from
October 1, 2024 23:38
0763904 to
4d703c2
Compare
mellyeliu
force-pushed
the
enforce-stylex-extension
branch
from
October 1, 2024 23:57
4d703c2 to
249598d
Compare
Member
Author
|
Processing for default exports, general refactor to shared functions |
mellyeliu
force-pushed
the
enforce-stylex-extension
branch
from
October 2, 2024 00:08
249598d to
b27a597
Compare
nmn
approved these changes
Oct 2, 2024
nmn
left a comment
Collaborator
There was a problem hiding this comment.
Nice big improvement. Thanks!
Open
2 tasks done
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Context
This ESLint rule ensures consistency in file naming conventions when exporting
stylex.defineVars.Specifically:
stylex.defineVarsmust end with.stylex.jsxor.stylex.tsxstylex.defineVarsmust not use the.stylex.jsxor.stylex.tsxextensions.custom.jsx), defaulting to.stylex.jsx.Test Cases:
Valid cases:
stylex.defineVarsexport correctly using.stylex.jsx,.stylex.tsx, or custom extensions.stylex.defineVarsexport using non-.stylex extensions.Invalid cases:
Files exporting
stylex.defineVarswithout the correct extension.Files not exporting
stylex.defineVarsbut using.stylex.jsx/.tsxor custom extensions incorrectly.I have read the contributing guidelines
Contribution Guidelines
Performed a self-review of my code