Skip to content
This repository was archived by the owner on Oct 24, 2019. It is now read-only.

Commit 9398e95

Browse files
authored
feat: exclude grid lifecycle event on bindEventHandlers (#8)
1 parent bb72edd commit 9398e95

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ export default class Grid extends React.Component {
1515

1616
bindEventHandlers(props, prevProps) {
1717
Object.keys(props)
18-
.filter(key => /on[A-Z][a-zA-Z]+/.test(key))
18+
.filter(key => /on(?!Grid)[A-Z][a-zA-Z]+/.test(key))
1919
.forEach(key => {
2020
const eventName = key[2].toLowerCase() + key.slice(3);
2121
// For <Grid onFocus={condition ? onFocus1 : onFocus2} />

0 commit comments

Comments
 (0)