This repository was archived by the owner on Sep 21, 2019. It is now read-only.
Commit a2338d9
Keep other static class members, such as defaultProps (#36)
* Add test for defaultProps
* Check if the name == "propTypes", not != " propTypes"
* More ways of getting the class member name (hacky)
* Check if we're an identifier; if we are we can just always use name.escapedText
* Use ts.isIdentifier helper function instead of direct comparison on .kind1 parent 1e17c1b commit a2338d9
File tree
3 files changed
+21
-1
lines changed- src/helpers
- test/react-remove-static-prop-types-member-transform/other-static-members
3 files changed
+21
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
97 | 97 | | |
98 | 98 | | |
99 | 99 | | |
100 | | - | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
101 | 103 | | |
102 | 104 | | |
103 | 105 | | |
| |||
Lines changed: 8 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
Lines changed: 10 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
0 commit comments