-
Notifications
You must be signed in to change notification settings - Fork 23
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: cover dynamic values in weak prop codemod and simplify it
- Loading branch information
Martí Malek
committed
Sep 19, 2023
1 parent
e31e550
commit 4f8e1ff
Showing
5 changed files
with
30 additions
and
9 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,2 @@ | ||
codemods/__testfixtures__ | ||
package-lock.json |
7 changes: 7 additions & 0 deletions
7
src/codemods/__testfixtures__/weak-to-secondary/dynamic-value.input.tsx
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
import { Text } from '@freenow/wave'; | ||
|
||
export const TextTest = () => ( | ||
<Text weak={Date.now() % 2 === 0} fontSize={1}> | ||
Just a text | ||
</Text> | ||
); |
7 changes: 7 additions & 0 deletions
7
src/codemods/__testfixtures__/weak-to-secondary/dynamic-value.output.tsx
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
import { Text } from '@freenow/wave'; | ||
|
||
export const TextTest = () => ( | ||
<Text secondary={Date.now() % 2 === 0} fontSize={1}> | ||
Just a text | ||
</Text> | ||
); |
This file contains 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
This file contains 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