Comments (9)
- login to your dashboard (https://dash.cloudflare.com/login)
- select account/website
- go to Speed > Optimization > Content Optimization
- disable Auto Minify
from vitepress.
Disable auto-minify in your host and vitepress is not removing that .html either. You probably have clean urls enabled in your host / or have auto-redirects set up.
from vitepress.
Hi @brc-dd thanks for the prompt reply, this is my config.mjs
:
import { defineConfig } from "vitepress";
// https://vitepress.dev/reference/site-config
export default defineConfig({
title: "s3m",
description: "A command-line tool for storing and sharing files on S3",
head: [
[
"link",
{
rel: "apple-touch-icon",
sizes: "120x120",
href: "/assets/favicons/apple-touch-icon-120x120.png",
},
],
["link", { rel: "icon", href: "/favicon.ico" }],
],
themeConfig: {
// https://vitepress.dev/reference/default-theme-config
nav: [
{ text: "Issues", link: "https://github.com/s3m/s3m/issues" },
{ text: "About", link: "/about" },
],
sidebar: [
{
text: "Commands",
items: [
{ text: "acl (ACL)", link: "/acl" },
{ text: "cb (Create bucke)", link: "/cb" },
{ text: "get (download)", link: "/get" },
{ text: "ls (list)", link: "/ls" },
{ text: "put (stream)", link: "/stream" },
{ text: "rm (delete)", link: "/rm" },
{ text: "share", link: "/share" },
{ text: "show", link: "/show" },
],
},
{
text: "How it works",
link: "/how-it-works",
},
{
text: "Install",
link: "/install",
},
{
text: "config.yml",
link: "/config",
},
{
text: "Stream",
link: "/stream",
},
],
socialLinks: [{ icon: "github", link: "https://github.com/s3m/s3m" }],
footer: {
message: "Released under the BSD License.",
},
},
});
But where do disable auto-minify and check for clean urls / auto-redirects?
from vitepress.
Where are you hosting your site?
from vitepress.
In cloudflare pages
from vitepress.
for auto-redirect thing maybe check Rules > Page Rules / Transform Rules and remove those
from vitepress.
Hi, many thanks I change it to:
Regarding transform rules I don't have any, this one is only enable but I think is not a problem:
from vitepress.
Hi @brc-dd 🥇 many thanks it is working now
from vitepress.
It's still not correct though. It should not send 308 for config.html
:
![image](https://private-user-images.githubusercontent.com/40380293/340973655-f876770b-af5a-4a35-a88a-182dc1c78bf0.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjMxOTEyMDUsIm5iZiI6MTcyMzE5MDkwNSwicGF0aCI6Ii80MDM4MDI5My8zNDA5NzM2NTUtZjg3Njc3MGItYWY1YS00YTM1LWE4OGEtMTgyZGMxYzc4YmYwLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA4MDklMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwODA5VDA4MDgyNVomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTgxYTEyNzA5NmQ5NDE2NWYwNzc4M2EzMzRmMWQ2NTI3MzY1M2QyNWQ2ZDdkMmYyY2M3MTVhNjY3MzQwNTc2YmYmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.BWM-97YlDYNXN51z43OkWDZMIhgIuUZ0IE0IAGq7Zk8)
There might some other option there 👀
Ah looks like there is no option - https://community.cloudflare.com/t/is-there-an-option-prevent-removing-the-html-suffix/494412
I think you can try enabling vitepress' cleanUrl too to match the behavior:
export default defineConfig({
cleanUrls: true,
// ... other stuff ...
})
from vitepress.
Related Issues (20)
- How to render {{Hello World}}, the Hello World will be replaced HOT 1
- support protobuf highlight HOT 1
- base配置打包之后少了斜杠,变成https:/www.baidu.com/logo.svg HOT 4
- 页面导航问题求教 HOT 1
- Hero images are not built correctly HOT 1
- Styling discrepancies between dev and build HOT 8
- Hydration completed but contains mismatches when linking directly to pages HOT 2
- I need help to customize vitepress
- loaderMatch need more limit
- Need to customize 404 page title HOT 3
- What about using markdown extension syntax for multilingual translation? HOT 1
- Content disappeared after navigation (refresh on page or navigation accessing to page) HOT 2
- Firefox: after clicking sidebar and nav links, cursor sticks on `default`
- Distinguish style isolation, router isolation, and both HOT 3
- need `onAfterPageLoad` in useRouter HOT 1
- Sidebar's base need extends parent's base HOT 3
- Type mismatching with @types/markdown-it 14.1.2 HOT 2
- Only index pages for searching under the same directory
- 手机端英文显示效果似乎不佳 HOT 2
- `lastUpdated` Feature Seems Not Displaying Date on Server Deployment Without Git HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from vitepress.