1
votes

I have migrated my angular application from Angular 5 to 6, when I am calling router navigation,

this.router.navigate(['doctor-log-in']).then(function (res) {
       console.log(res);
     }, function (err) {
       console.log('in errrrr');
       console.log(err);
     });

it's giving below error

main.9819f0c7d0ec0efd5341.js:1 TypeError: Cannot read property 'OVERWRITE' of undefined at new n (main.9819f0c7d0ec0efd5341.js:1) at n.applyServerOverwrite

1

1 Answers

0
votes

Run below command to generate dist folder.

npm run build --prod

instead of

ng build --prod

then it's working.