Skip to content

Instantly share code, notes, and snippets.

@jstrimpel
Last active August 29, 2015 14:19
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save jstrimpel/93c23f5ce249f8a48da9 to your computer and use it in GitHub Desktop.
Save jstrimpel/93c23f5ce249f8a48da9 to your computer and use it in GitHub Desktop.
react custom attribute support
React.config({
HTMLDOMPropertyConfig: {
isCustomAttribute: RegExp.prototype.test.bind(/^(data|aria|lazo)-[a-z_][a-z\d_.\-]*$/),
Properties: {
'some-other-prop': null
}
});
// would trigger ReactInjection.DOMProperty.injectDOMPropertyConfig(HTMLDOMPropertyConfig);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment