-
Notifications
You must be signed in to change notification settings - Fork 5
Description
[feature request] Please can we have a codemod that will automatically convert a React Native project from using StyleSheet.create to styled-components? A sort of opposite to https://github.com/styled-components/css-to-react-native ?
Use case:
John the developer has a React Native app. He used the built in React Native StyleSheet.create method for CSS styling. John also makes websites. John keeps on accidentally using the wrong syntax in React Native because it is similar but slightly different to web css syntax. (A UX mode error.) John wastes a lot of expensive developer time fixing these syntax errors. Particularly terminating a line of css with a semicolon ; when it should be a comma , or vice versa. John then shouts at his partner. John kicks the dog.
John then runs a codemod to convert his React Native code to use styled-components. John now uses the same css syntax when writing apps and websites. John makes less syntax errors. John always terminates a line of css with a semi-colon. John is happy. In the time freed up by not having to fix syntax mode errors John investigates writing universal apps using react-native-web or similar. John is productive. John proposes to his partner. John gives his dog a bone. They all live happily ever after.