@sleetch/client 1.0.8 → 1.0.9

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 CHANGED
@@ -1 +1,4 @@
1
- export {}
1
+ //#region src/lib/clean-path.d.ts
2
+ declare function clean_path(_path?: string): string;
3
+ //#endregion
4
+ export { clean_path };
package/dist/index.js CHANGED
@@ -1 +1,11 @@
1
- export {};
1
+ //#region src/lib/clean-path.ts
2
+ function clean_path(_path) {
3
+ if (!_path || _path.length === 0) _path = "/";
4
+ else if (_path !== "/") {
5
+ if (!_path.startsWith("/", 0)) _path = `/${_path}`;
6
+ if (_path.endsWith("/")) _path = _path.slice(0, -1);
7
+ }
8
+ return _path;
9
+ }
10
+ //#endregion
11
+ export { clean_path };
package/package.json CHANGED
@@ -1,33 +1,34 @@
1
1
  {
2
- "name": "@sleetch/client",
3
- "version": "1.0.8",
4
- "type": "module",
5
- "files": [
6
- "dist",
7
- "src/styles"
8
- ],
9
- "publishConfig": {
10
- "access": "public"
11
- },
12
- "scripts": {
13
- "build": "tsdown",
14
- "dev": "tsdown --watch"
15
- },
16
- "dependencies": {
17
- "@sleetch/core": "1.0.8",
18
- "@sleetch/styles": "1.0.8"
19
- },
20
- "exports": {
21
- ".": "./dist/index.js",
22
- "./package.json": "./package.json",
23
- "./markdown.css": {
24
- "default": "./src/styles/markdown.css"
25
- },
26
- "./base.css": {
27
- "default": "./src/styles/base.css"
28
- },
29
- "./manifest": "./.sleetch/manifest.js",
30
- "./trees/*": "./.sleetch/trees/*.js",
31
- "./pages/*": "./.sleetch/pages/*.js"
32
- }
2
+ "name": "@sleetch/client",
3
+ "version": "1.0.9",
4
+ "type": "module",
5
+ "files": [
6
+ "dist",
7
+ "src/styles"
8
+ ],
9
+ "publishConfig": {
10
+ "access": "public"
11
+ },
12
+ "scripts": {
13
+ "build": "tsdown",
14
+ "dev": "tsdown --watch"
15
+ },
16
+ "dependencies": {
17
+ "@sleetch/core": "1.0.9",
18
+ "@sleetch/styles": "1.0.9"
19
+ },
20
+ "exports": {
21
+ ".": "./dist/index.js",
22
+ "./package.json": "./package.json",
23
+ "./markdown.css": {
24
+ "default": "./src/styles/markdown.css"
25
+ },
26
+ "./base.css": {
27
+ "default": "./src/styles/base.css"
28
+ },
29
+ "./manifest": "./.sleetch/manifest.js",
30
+ "./manifest-cache-bust": "./.sleetch/manifest-esm-cache-bust.js",
31
+ "./trees/*": "./.sleetch/trees/*.js",
32
+ "./pages/*": "./.sleetch/pages/*.js"
33
+ }
33
34
  }