@rspress/shared 0.0.0-nightly-20240418160241 → 0.0.0-nightly-20240420160241

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -1279,6 +1279,9 @@ function normalizeHref(url, cleanUrls = false) {
1279
1279
  if (cleanUrls && cleanUrl2.endsWith("/")) {
1280
1280
  cleanUrl2 += "index";
1281
1281
  }
1282
+ if (cleanUrls && cleanUrl2.endsWith(".html")) {
1283
+ cleanUrl2 = cleanUrl2.replace(/\.html$/, "");
1284
+ }
1282
1285
  return addLeadingSlash(hash ? `${cleanUrl2}#${hash}` : cleanUrl2);
1283
1286
  }
1284
1287
  function withoutLang(path, langs) {
package/dist/index.mjs CHANGED
@@ -1221,6 +1221,9 @@ function normalizeHref(url, cleanUrls = false) {
1221
1221
  if (cleanUrls && cleanUrl2.endsWith("/")) {
1222
1222
  cleanUrl2 += "index";
1223
1223
  }
1224
+ if (cleanUrls && cleanUrl2.endsWith(".html")) {
1225
+ cleanUrl2 = cleanUrl2.replace(/\.html$/, "");
1226
+ }
1224
1227
  return addLeadingSlash(hash ? `${cleanUrl2}#${hash}` : cleanUrl2);
1225
1228
  }
1226
1229
  function withoutLang(path, langs) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rspress/shared",
3
- "version": "0.0.0-nightly-20240418160241",
3
+ "version": "0.0.0-nightly-20240420160241",
4
4
  "types": "./dist/index.d.ts",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.mjs",