Open VytautasT opened 5 years ago
import { connect } from 'react-redux';
class Counter extends Component = () => {
return <div>{this.props.counter}</div>
}
function mapStateToProps(state) {
return {
counter: state.counter
}
}
export default connect(mapStateToProps)(Counter)
with Hooks
import { useSelector } from 'react-redux';
export const Counter = () => {
const counter = useSelector(state => state.counter);
return <div>{counter}</div>
}
Interesting @2012mjm. It should be quiet easy to add it. The only concern I have - should this be a separate extension or not? I mean, identifying usage of a certain library can be quiet difficult. WDYT?
Hey @VytautasT. Can you elaborate/provide example?