Sort StyleProps alphabetically
Summary: Sorting the StyleProps alphabetically makes it easier to scan through the list of available props e.g. in case of typos. Filled out the FB CLA form just now. Related to #1605 Closes https://github.com/facebook/react-native/pull/1607 Github Author: Jan Monschke <jan.monschke@gmail.com> Test Plan: Imported from GitHub, without a `Test Plan:` line.
This commit is contained in:
parent
d3065fc2e7
commit
e2fc7d2362
|
@ -26,7 +26,7 @@ class StyleSheetValidation {
|
|||
if (allStylePropTypes[prop] === undefined) {
|
||||
var message1 = '"' + prop + '" is not a valid style property.';
|
||||
var message2 = '\nValid style props: ' +
|
||||
JSON.stringify(Object.keys(allStylePropTypes), null, ' ');
|
||||
JSON.stringify(Object.keys(allStylePropTypes).sort(), null, ' ');
|
||||
styleError(message1, style, caller, message2);
|
||||
}
|
||||
var error = allStylePropTypes[prop](
|
||||
|
|
Loading…
Reference in New Issue