-
Notifications
You must be signed in to change notification settings - Fork 47.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Warn when using hyphenated style property names #1662
Warn when using hyphenated style property names #1662
Conversation
if (__DEV__) { | ||
var warnedStyleNames = {}; | ||
|
||
var warnHyphenatedStyleName = function (name) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: no space after function
Looks pretty good to me. After getting |
I updated the code. |
|
beforeEach(function() { | ||
require('mock-modules').dumpCache(); | ||
CSSPropertyOperations = require('CSSPropertyOperations'); | ||
|
||
mocks = require('mocks'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you need mocks
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah right. I only found spyOn
later and tried using mocks at first. Will remove.
What do you think about also warning if someone writes |
Seems reasonable, but let's do that in a second PR |
@zpao I rebased it to use the synced |
…e-names Warn when using hyphenated style property names Closes #1662 Conflicts: src/browser/ui/dom/CSSPropertyOperations.js
Sorry this took so long to get in! |
Thank you! |
Fixes #932