Angular Function calls are not supported in decorators but 'InjectionToken' was called in

Angular ng build --prod 時報錯的解決方法紀錄

Function calls are not supported in decorators but 'InjectionToken' was called in 'OWL_MOMENT_DATE_TIME_ADAPTER_OPTIONS'

tsconfig.json

"paths": {
    //...

    "@angular/*": ["../node_modules/@angular/*"]
}

參照:https://github.com/angular/angular/issues/16762

PS5