Skip to content
This repository has been archived by the owner on Apr 6, 2023. It is now read-only.

fix: set vite's root to current directory #239

Merged
merged 6 commits into from
Jul 14, 2021
Merged

fix: set vite's root to current directory #239

merged 6 commits into from
Jul 14, 2021

Conversation

antfu
Copy link
Member

@antfu antfu commented Jun 18, 2021

packages/nuxt3/src/builder.ts Outdated Show resolved Hide resolved
packages/app/src/_templates/views/app.template.html Outdated Show resolved Hide resolved
packages/nuxt3/src/builder.ts Outdated Show resolved Hide resolved
packages/vite/src/vite.ts Outdated Show resolved Hide resolved
@antfu
Copy link
Member Author

antfu commented Jul 10, 2021

Should be resolved

@pi0
Copy link
Member

pi0 commented Jul 12, 2021

Thanks @antfu. What do you think of using /app alias (like this) to avoid putting full fs path?

@antfu
Copy link
Member Author

antfu commented Jul 12, 2021

Thanks for the pointer! I have changed the template using #build, however the warmupViteServer does not resolve the alias so I left the full path for it, is that good to you?

@pi0
Copy link
Member

pi0 commented Jul 12, 2021

however the warmupViteServer does not resolve the alias so I left the full path for it, is that good to you?

Yeah makes sense for now :)

Thanks for the pointer! I have changed the template using #build

src="#build/entry.mjs" I think this doesn't work in browser (# in URL not being sent to server) that's why added /app in addition.

@antfu
Copy link
Member Author

antfu commented Jul 12, 2021

Do we need to use something like /__app and /__build in case of the conflicting with user defined routes?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Set Vite's root cwd() instead of .nuxt
3 participants