-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
srcExclude
doesn't work with vitepress dev
#4310
Comments
Indeed, I think that's an issue with |
In dev, those paths won't be discovered by default, but if you access those paths, vite won't block them either. |
I see, so this is expected in |
srcExclude
doesn't worksrcExclude
doesn't work with vitepress dev
You can restrict them though if you want: vite: {
server: {
fs: {
deny: ["README.md", "infra/**"],
},
},
}, |
Yeah, I see, I just wasn't aware of how dev mode differs in this regard. Frankly, I know nothing about vite though 😅, I just tried the |
Describe the bug
I tried this config:
But it doesn't work, I still see a web page generated at
/README
and at/infra/README
. The source code of my project is hereReproduction
Then add the config mentioned above to
.vitepress/config.mts
, and start the dev server:I also tried
**/README.md
and**/infra/**
, it didn't help.Expected behavior
There should be no
/README
andinfra/README
pages generated.System Info
Validations
The text was updated successfully, but these errors were encountered: