ProductionViteSpaScripts.cshtml path fixes.#21
Open
hdimon wants to merge 1 commit into
Open
Conversation
Contributor
Author
|
Please publish new version of Nuget and NPM packages when you have time - it's really needed. |
Owner
|
I just created a new version of both the nuget and npm packages.
…On Fri, Nov 24, 2023, 2:32 PM hdimon ***@***.***> wrote:
Please publish new version of Nuget and NPM packages when you have time -
it's really needed.
—
Reply to this email directly, view it on GitHub
<#21 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AEBJ7ALOGB4TJSFB4QGOXVTYGD77JAVCNFSM6AAAAAA7IFBIGGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQMRWGA3DONJYGE>
.
You are receiving this because you are subscribed to this thread.Message
ID: ***@***.***>
|
Contributor
Author
|
Thank you! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Some issue in paths for css and scripts in ProductionViteSpaScripts.cshtml.
How did I find it:
app.MapFallbackToPage("/{*catchall}", "/Index"). Now when you go to this address and refresh page then page is opened but scripts are not loaded because they are tried to be loaded from addresses like:https://localhost:7104/admin/AdminApp/main.228761a0.js
https://localhost:7104/admin/AdminApp/main.951a8be3.css
i.e. file paths are relative to current address (https://localhost:7104/admin/) instead of root (https://localhost:7104/). Correct paths are:
https://localhost:7104/AdminApp/main.228761a0.js
https://localhost:7104/AdminApp/main.951a8be3.css
Changes are supposed to fix it. Honestly I'm not 100% sure that it's fully correct fix for all environments. I had idea to use Environment.WebRootPath but have doubts (there was mix of forward slashes and backslashes). So if you see more appropriate way to fix that then please do:).