File tree Expand file tree Collapse file tree 2 files changed +7
-2
lines changed Expand file tree Collapse file tree 2 files changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -159,7 +159,11 @@ async function main() {
159159 if ( backgroundColor != null ) {
160160 window . document . body . style . backgroundColor = backgroundColor ;
161161 }
162- const root = ReactDOM . createRoot ( document . getElementById ( "demo-desktop" ) ) ;
162+ const div = document . getElementById ( "demo-desktop" ) ;
163+ if ( div == null ) {
164+ throw new Error ( "Could not locate #demo-desktop div" ) ;
165+ }
166+ const root = ReactDOM . createRoot ( div ) ;
163167 root . render (
164168 < DemoDesktop webamp = { webamp } soundCloudPlaylist = { soundcloudPlaylist } />
165169 ) ;
Original file line number Diff line number Diff line change 1010 "strict" : true ,
1111 "jsx" : " preserve" ,
1212 "noEmit" : true ,
13- "pretty" : true
13+ "pretty" : true ,
14+ "types" : [" react/experimental" , " react-dom/experimental" ]
1415 },
1516 "include" : [" **/*.ts" , " **/*.tsx" ],
1617 "exclude" : [" node_modules" , " demo/built" ]
You can’t perform that action at this time.
0 commit comments