Skip to content

Commit

Permalink
prettier + alphabetize
Browse files Browse the repository at this point in the history
  • Loading branch information
sophiebits authored Oct 31, 2023
1 parent 35d0c05 commit 9ef29fb
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion packages/react-dom-bindings/src/client/validateDOMNesting.js
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,12 @@ function isTagValidWithParent(tag: string, parentTag: ?string): boolean {
switch (parentTag) {
// https://html.spec.whatwg.org/multipage/syntax.html#parsing-main-inselect
case 'select':
return tag === 'option' || tag === 'optgroup' || tag === '#text' || tag === 'hr';
return (
tag === 'hr' ||
tag === 'option' ||
tag === 'optgroup' ||
tag === '#text'
);
case 'optgroup':
return tag === 'option' || tag === '#text';
// Strictly speaking, seeing an <option> doesn't mean we're in a <select>
Expand Down

0 comments on commit 9ef29fb

Please sign in to comment.