Document iframe is created and inserted into the page by yourself, not through calling ZofficeSDK.mount, then calling ZofficeSDK.connect. During document loading, an error occurred and the document cannot be opened, but ZofficeSDK.connect returns null after a long time (40-50 seconds). It needs to return null immediately when error prompt appears.
Answer:
The difference between mount and connect is that the former actively creates an iframe and loads the document, while the latter is used when an iframe already exists. So the former covers the entire lifecycle from document loading to complete display, while the latter, depending on when it is called, is either called during document loading or after the document has already loaded. So the latter may not know what errors occurred during document loading. Therefore, if you need to pay attention to the document loading process, it is recommended to use mount instead of connect, which can solve the problem.