Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions packages/react-dom/src/server/ReactDOMServerFormatConfig.js
Original file line number Diff line number Diff line change
Expand Up @@ -729,15 +729,16 @@ function pushStartOption(
}
}
break;
case 'value':
value = propValue;
break;
case 'dangerouslySetInnerHTML':
invariant(
false,
'`dangerouslySetInnerHTML` does not work on <option>.',
);
// eslint-disable-next-line-no-fallthrough
case 'value':
value = propValue;
// We intentionally fallthrough to also set the attribute on the node.
// eslint-disable-next-line-no-fallthrough
default:
pushAttribute(target, responseState, propKey, propValue);
break;
Expand Down
8 changes: 4 additions & 4 deletions packages/react-server/src/ReactFizzServer.js
Original file line number Diff line number Diff line change
Expand Up @@ -563,11 +563,11 @@ function renderClassComponent(
Component: any,
props: any,
): void {
const unmaskedContext = !disableLegacyContext
? task.legacyContext
const maskedContext = !disableLegacyContext
? getMaskedContext(Component, task.legacyContext)
: undefined;
const instance = constructClassInstance(Component, props, unmaskedContext);
mountClassInstance(instance, Component, props, unmaskedContext);
const instance = constructClassInstance(Component, props, maskedContext);
mountClassInstance(instance, Component, props, maskedContext);
finishClassComponent(request, task, instance, Component, props);
}

Expand Down