SharePoint Online / Angular - Error: Uncaught Error: Zone already loaded

%3CLINGO-SUB%20id%3D%22lingo-sub-2184084%22%20slang%3D%22en-US%22%3ESharePoint%20Online%20%2F%20Angular%20-%20Error%3A%20Uncaught%20Error%3A%20Zone%20already%20loaded%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2184084%22%20slang%3D%22en-US%22%3E%3CP%3EWe%20currently%20have%20a%20serious%20production%20issue%20with%20two%20SharePoint%20Online%20customers.%20On%20Classic%20Pages%20when%20you%20add%20an%20Angular%20app%2C%20the%20app%20does%20not%20work.%20There%20is%20an%20error%20in%20the%20console%3A%20Zone%20already%20loaded.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EOn%20Modern%20Pages%20Angular%20apps%20still%20works.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22SirJoey_0-1614844805645.jpeg%22%20style%3D%22width%3A%20400px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F260756i70910168220B4793%2Fimage-size%2Fmedium%3Fv%3D1.0%26amp%3Bpx%3D400%22%20role%3D%22button%22%20title%3D%22SirJoey_0-1614844805645.jpeg%22%20alt%3D%22SirJoey_0-1614844805645.jpeg%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EAccording%20to%20this%20post%3A%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fstackoverflow.com%2Fquestions%2F66469814%2Fsharepoint-online-angular-error-uncaught-error-zone-already-loaded%2C%22%20target%3D%22_blank%22%20rel%3D%22noopener%20nofollow%20noreferrer%22%3Ehttps%3A%2F%2Fstackoverflow.com%2Fquestions%2F66469814%2Fsharepoint-online-angular-error-uncaught-error-zone-already-loaded%2C%3C%2FA%3E%26nbsp%3Bthe%20workaround%20is%20to%20add%20the%20following%20code.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CPRE%20class%3D%22lia-code-sample%20language-javascript%22%3E%3CCODE%3Ewindow.Zone%20%3D%20undefined%3B%3C%2FCODE%3E%3C%2FPRE%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EAny%20ideas%3F%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-2184084%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3Eangular%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3ESharePoint%20Online%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E
Regular Visitor

We currently have a serious production issue with two SharePoint Online customers. On Classic Pages when you add an Angular app, the app does not work. There is an error in the console: Zone already loaded.

 

On Modern Pages Angular apps still works.

 

SirJoey_0-1614844805645.jpeg

 

According to this post: https://stackoverflow.com/questions/66469814/sharepoint-online-angular-error-uncaught-error-zone-alr... the workaround is to add the following code.

 

 

window.Zone = undefined;

 

 

Microsoft is pushing the following file which contains a lot of globally defined functions. That is the cause. I guess everyone which uses Angular apps on Classic Pages will get this error.

 

SirJoey_1-1614860375030.png

 

 

 

0 Replies