Created
November 25, 2018 23:41
-
-
Save kiraind/261821adfc7291161db1d4b70bd81b67 to your computer and use it in GitHub Desktop.
Create new react component
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
mkdir "src/components/$1" | |
echo "import React from 'react' | |
import './$1.css' | |
export default class $1 extends React.Component { | |
render() { | |
return ( | |
<div className=\"$1\"> | |
</div> | |
) | |
} | |
}" | cat > src/components/$1/$1.js | |
echo ".$1 { | |
}" | cat > src/components/$1/$1.css | |
code -g src/components/$1/$1.js:9:17 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment