When i start angular app with "ng serve" command, I see the below errors in the chrome developer tools console:
Angular is running in the development mode. Call enableProdMode() to enable the production mode.
index.js:7 Error: Invalid value type
at Function.a.set (index.js:7)
at t.setIsTrutedEnforced (index.js:7)
at index.js:49
a.set @ index.js:7
t.setIsTrutedEnforced @ index.js:7
(anonymous) @ index.js:49
Promise.then (async)
h @ index.js:49
(anonymous) @ index.js:49
(anonymous) @ index.js:7
n @ index.js:49
index.js:7 Uncaught (in promise) Error: Given action "NormalMode/SetPageData", reducer "isTrustedEnforced" returned undefined. To ignore an action, you must explicitly return the previous state. If you want this reducer to hold no value, you can return null instead of undefined.
at index.js:7
at Object.g [as dispatch] (index.js:7)
at t.SetPageData (index.js:7)
at index.js:49
You have to provide some logic in main.ts to prevent this issue.
Add the below code to your main.ts file.