renderAardvarkRoot(element: HTMLElement | string, gadgetMain: Element | (() => Element), browserMain?: Element | (() => Element)): Promise<void>
Uses ReactDOM to render the appropriate main component. If The gadget is running in Aardvark,
this function will wait for it to connect to the local Aardvark server and then render gadgetMain.
If the gadget is running in another browser this function will render browserMain.
Parameters
element: HTMLElement | string
the element to render on or the ID of an element
gadgetMain: Element | (() => Element)
The React component to render when running in Aardvark.
Optional browserMain: Element | (() => Element)
The React component to render when running in another browser. If this is undefined
an instance of DefaultLanding will be rendered.
Uses ReactDOM to render the appropriate main component. If The gadget is running in Aardvark, this function will wait for it to connect to the local Aardvark server and then render gadgetMain. If the gadget is running in another browser this function will render browserMain.