MCPcopy Create free account
hub / github.com/ZenNotes/zennotes / renderZenNotesApp

Function renderZenNotesApp

packages/app-core/src/main.tsx:21–43  ·  view source on GitHub ↗
(root: HTMLElement)

Source from the content-addressed store, hash-verified

19})
20
21export function renderZenNotesApp(root: HTMLElement): void {
22 const params = new URLSearchParams(window.location.search)
23 const isFloating = params.get('floating') === '1'
24 const isQuickCapture = params.get('quickCapture') === '1'
25 const isExternalFile = params.get('externalFile') !== null
26 const floatingNotePath = params.get('note')
27
28 ReactDOM.createRoot(root).render(
29 <React.StrictMode>
30 <Suspense fallback={null}>
31 {isQuickCapture ? (
32 <QuickCaptureApp />
33 ) : isExternalFile ? (
34 <ExternalFileApp />
35 ) : isFloating && floatingNotePath ? (
36 <FloatingNoteApp notePath={floatingNotePath} />
37 ) : (
38 <App />
39 )}
40 </Suspense>
41 </React.StrictMode>
42 )
43}

Callers 2

main.tsxFile · 0.90
main.tsxFile · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected