-
-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[fix] replace kit.paths.base if it runs on localhost #2318
Conversation
🦋 Changeset detectedLatest commit: e56abff The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
edit: I fixed it up. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lgtm
Another PR to fix this issue has been submitted to fix |
Ok, I'll just go ahead and close it now then |
fix: #2230
Before submitting the PR, please make sure you do the following
Tests
pnpm test
and lint the project withpnpm lint
andpnpm check
Changesets
pnpx changeset
and following the prompts. All changesets should bepatch
until SvelteKit 1.0Explain What I Did
In this PR #2189, the way of handle for
kit.paths.assets
insvelte.config.js
was changed.After that, the issue #2230 comes.
I think this issue is only a problem in a dev environment like localhost.
(Please check details at here)
So I just handled this issue as like workaround code.
As an alternative way, we can modify module bunder (like Vite).
In this case, we can create a folder which is the value of
kit.paths.assets
as the parent of the_app
folder. (And maybe something more.)But in my opinion, we will have a chance to handle this issue for each module bundler.
This is just a little bit troublesome.
Therefore I choose this simple way.
So could you please review this way is reasonable?
Or should I modify Vite or somewhere else?
MEMO
I don't know how to do the brawser test with
npm run dev
command. Please tell me how can I add a test for it.When I execute
pnpx changeset
, it showsIf you are unsure if this is correct, contact the package's maintainers before committing this changeset
, so now I didn't create changeset. (After getting a review comment, I will create it.)Thank you!