babel-plugin-collect-react-props
v1.0.0
Published
a plugin help you collect react application props
Downloads
3
Readme
babel-plugin-collect-react-props
a plugin help you collect react application props
usage
you react application
function Foo() { return ( <div> <button vant="1">1</button> <button vant="2">1</button> <button vant="3">1</button> <button iview="4">1</button> </div> ) }
babel config
[ "collect-react-props", { "collectKey": [ "vant", "iview" ] } ]
then you will get
{ vant: ['1', '2', '3'], iview: ['4'] }