Skip to content

Commit 8021604

Browse files
committed
Remove error throwing behavior for Localized without a Provider
1 parent a67a0b7 commit 8021604

File tree

1 file changed

+0
-6
lines changed

1 file changed

+0
-6
lines changed

fluent-react/src/localized.js

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -55,12 +55,6 @@ function Localized(props) {
5555
const { id, attrs, children: child = null } = props;
5656
const { l10n, parseMarkup } = useContext(FluentContext);
5757

58-
if (l10n === null) {
59-
throw new Error(
60-
"<Localized/> needs to have a <LocalizationProvider/> up in the tree"
61-
);
62-
}
63-
6458
// Validate that the child element isn't an array
6559
if (Array.isArray(child)) {
6660
throw new Error("<Localized/> expected to receive a single " +

0 commit comments

Comments
 (0)