且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

SAP Spartacus 3.0部署在development environment上

更新时间:2022-09-04 19:11:45

SAP Spartacus 3.0部署在development environment上

启动Spartacus,遇到错误消息:


NullInjectorError: R3InjectorError(AppServerModule)[ApplicationModule -> ApplicationRef -> ApplicationInitStatus -> InjectionToken Application Initializer -> [object Object] -> InjectionToken ConfigInitializer -> [object Object] -> spartacus_core_OccConfigLoaderService -> InjectionToken SERVER_REQUEST_URL -> InjectionToken SERVER_REQUEST_URL -> InjectionToken SERVER_REQUEST_URL -> InjectionToken REQUEST]:


NullInjectorError: No provider for InjectionToken REQUEST!


解决方法

In the mean time could you check in your storefront’s “package.json” file. You should see a dependency named “@nguniversal/express-engine” and a devDependency named “@nguniversal/builders”. They are most likely both on version “^9.1.0”. Can you try changing them both to “^10.1.0” and push those changes to your release branch. You will then need to create a new build and deployment.That should resolve the issue.