在将.NET 5升级到.NET 6后,在EPiServer模块中加载JavaScript文件时出现错误。

huangapple go评论61阅读模式
英文:

Error loading JavaScript file in EPiServer module after upgrading from .NET 5 to .NET 6

问题

我最近将我的 Episerver 项目的自定义模块从 .NET 5 升级到 .NET 6。在之前的版本中,该项目使用的是 Episerver 12.9.0,但升级后,现在使用的是 Episerver 12.19.0。

然而,在完成升级后,我遇到了一个错误,指示我的模块中的 JavaScript 文件找不到。在项目中,该文件位于 modules_protected[模块名称][版本]\ClientResources\scripts\editors 文件夹中。但当我加载项目时,它正在查找文件位于 [根目录]/ClientResources/ClientResources/scripts/editors/。

我尝试修改模块配置来修复文件路径,但似乎没有起作用。

请问有谁可以帮助我解决这个问题吗?谢谢!

英文:

I recently updated my Episerver project's custom module from .NET 5 to .NET 6. In the previous version, the project used Episerver 12.9.0, but after the upgrade, it now uses Episerver 12.19.0.

However, after completing the upgrade, I encountered an error indicating that the JavaScript file within my module cannot be found. In the project, the file was located in modules_protected[Module Name][Version]\ClientResources\scripts\editors folder. But when I load the project, it is looking for the file at [Root]/ClientResources/ClientResources/scripts/editors/.

I attempted to modify the module configuration to correct the file path, but it doesn't seem to be working.

Could anyone please help me resolve this issue? Thank you!

答案1

得分: 1

经过仔细检查根文件夹中的文件,我成功识别出错误的原因。我注意到那里存在一个module.config文件的副本。这就是导致错误抛出的原因。

英文:

After carefully examining the files in the root folder, I was able to identify the cause of the error. I noticed that there was a copy of the module.config file present. This was the reason behind the error being thrown.

huangapple
  • 本文由 发表于 2023年6月1日 14:02:09
  • 转载请务必保留本文链接:https://go.coder-hub.com/76379065.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定