babel-plugin-styled-name
Add displayName
and componentId
for styled-components.
Installation
$ npm install babel-plugin-styled-name --save-dev
Example
Improve readability in devTools
↓
How?
const Button = styledbutton` color: red;`
↓
const Button = styledbutton` color: red;`
Usage
Use only for development!
.babelrc
(Recommended)
Via .babelrc
Via CLI
$ babel --plugins styled-name script.js
Via Node API
;