From f88855da4fc30fac90391c079cd9bbf734ef35b2 Mon Sep 17 00:00:00 2001 From: Dale Seo <5466341+DaleSeo@users.noreply.github.com> Date: Sun, 11 Feb 2024 23:10:17 -0500 Subject: [PATCH] docs: non-null assertion is needed on document.getElementById (#8540) --- docs/bundler/index.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/bundler/index.md b/docs/bundler/index.md index d83631f93b..147350c750 100644 --- a/docs/bundler/index.md +++ b/docs/bundler/index.md @@ -43,7 +43,7 @@ Let's build our first bundle. You have the following two files, which implement import * as ReactDOM from 'react-dom/client'; import {Component} from "./Component" -const root = ReactDOM.createRoot(document.getElementById('root')); +const root = ReactDOM.createRoot(document.getElementById('root')!); root.render() ```