@rspress/shared 1.7.3 → 1.7.5
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.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/index.mjs +1 -1
- package/package.json +2 -2
package/dist/index.d.ts
CHANGED
@@ -685,7 +685,7 @@ declare function removeLeadingSlash(url: string): string;
|
|
685
685
|
declare function addTrailingSlash(url: string): string;
|
686
686
|
declare function removeTrailingSlash(url: string): string;
|
687
687
|
declare function normalizeSlash(url: string): string;
|
688
|
-
declare function isExternalUrl(url
|
688
|
+
declare function isExternalUrl(url?: string): boolean;
|
689
689
|
declare function replaceLang(rawUrl: string, lang: {
|
690
690
|
current: string;
|
691
691
|
target: string;
|
package/dist/index.js
CHANGED
@@ -1183,7 +1183,7 @@ function removeTrailingSlash(url) {
|
|
1183
1183
|
function normalizeSlash(url) {
|
1184
1184
|
return removeTrailingSlash(addLeadingSlash(normalizePosixPath(url)));
|
1185
1185
|
}
|
1186
|
-
function isExternalUrl(url) {
|
1186
|
+
function isExternalUrl(url = "") {
|
1187
1187
|
return url.startsWith("http://") || url.startsWith("https://") || url.startsWith("mailto:") || url.startsWith("tel:");
|
1188
1188
|
}
|
1189
1189
|
function replaceLang(rawUrl, lang, version, base = "") {
|
package/dist/index.mjs
CHANGED
@@ -1126,7 +1126,7 @@ function removeTrailingSlash(url) {
|
|
1126
1126
|
function normalizeSlash(url) {
|
1127
1127
|
return removeTrailingSlash(addLeadingSlash(normalizePosixPath(url)));
|
1128
1128
|
}
|
1129
|
-
function isExternalUrl(url) {
|
1129
|
+
function isExternalUrl(url = "") {
|
1130
1130
|
return url.startsWith("http://") || url.startsWith("https://") || url.startsWith("mailto:") || url.startsWith("tel:");
|
1131
1131
|
}
|
1132
1132
|
function replaceLang(rawUrl, lang, version, base = "") {
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@rspress/shared",
|
3
|
-
"version": "1.7.
|
3
|
+
"version": "1.7.5",
|
4
4
|
"types": "./dist/index.d.ts",
|
5
5
|
"main": "./dist/index.js",
|
6
6
|
"module": "./dist/index.mjs",
|
@@ -22,7 +22,7 @@
|
|
22
22
|
}
|
23
23
|
},
|
24
24
|
"dependencies": {
|
25
|
-
"@rsbuild/core": "0.0
|
25
|
+
"@rsbuild/core": "0.1.0",
|
26
26
|
"unified": "10.1.2",
|
27
27
|
"chalk": "4.1.2",
|
28
28
|
"rslog": "^1.1.0"
|