@scalar/helpers 0.0.5 → 0.0.6
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/CHANGELOG.md +6 -0
- package/dist/url/is-local-url.js.map +1 -1
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/url/is-local-url.ts"],
|
|
4
|
-
"sourcesContent": ["/** Obviously local hostnames */\nconst LOCAL_HOSTNAMES = ['localhost', '127.0.0.1', '[::1]', '0.0.0.0']\n\n/**\n * Detect requests to localhost\n */\nexport function isLocalUrl(url: string) {\n try {\n const { hostname } = new URL(url)\n\n return LOCAL_HOSTNAMES.includes(hostname)\n } catch {\n // If it
|
|
4
|
+
"sourcesContent": ["/** Obviously local hostnames */\nconst LOCAL_HOSTNAMES = ['localhost', '127.0.0.1', '[::1]', '0.0.0.0']\n\n/**\n * Detect requests to localhost\n */\nexport function isLocalUrl(url: string) {\n try {\n const { hostname } = new URL(url)\n\n return LOCAL_HOSTNAMES.includes(hostname)\n } catch {\n // If it's not a valid URL, we can't use the proxy anyway,\n // but it also covers cases like relative URLs (e.g. `openapi.json`).\n return true\n }\n}\n"],
|
|
5
5
|
"mappings": "AACA,MAAM,kBAAkB,CAAC,aAAa,aAAa,SAAS,SAAS;AAK9D,SAAS,WAAW,KAAa;AACtC,MAAI;AACF,UAAM,EAAE,SAAS,IAAI,IAAI,IAAI,GAAG;AAEhC,WAAO,gBAAgB,SAAS,QAAQ;AAAA,EAC1C,QAAQ;AAGN,WAAO;AAAA,EACT;AACF;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/package.json
CHANGED
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
"helpers",
|
|
15
15
|
"js"
|
|
16
16
|
],
|
|
17
|
-
"version": "0.0.
|
|
17
|
+
"version": "0.0.6",
|
|
18
18
|
"engines": {
|
|
19
19
|
"node": ">=20"
|
|
20
20
|
},
|
|
@@ -79,8 +79,8 @@
|
|
|
79
79
|
"module": "dist/index.js",
|
|
80
80
|
"devDependencies": {
|
|
81
81
|
"vite": "5.4.19",
|
|
82
|
-
"vitest": "^1.6.
|
|
83
|
-
"@scalar/build-tooling": "0.2.
|
|
82
|
+
"vitest": "^1.6.1",
|
|
83
|
+
"@scalar/build-tooling": "0.2.4"
|
|
84
84
|
},
|
|
85
85
|
"scripts": {
|
|
86
86
|
"build": "scalar-build-esbuild",
|