@bhsd/common 0.6.3 → 0.6.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.js +4 -7
- package/dist/index.mjs +1 -4
- package/eslintrc.cjs +7 -0
- package/package.json +19 -16
- package/.eslintrc.cjs +0 -16
package/dist/index.js
CHANGED
|
@@ -16,8 +16,8 @@ var __copyProps = (to, from, except, desc) => {
|
|
|
16
16
|
return to;
|
|
17
17
|
};
|
|
18
18
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
-
var
|
|
20
|
-
__export(
|
|
19
|
+
var index_exports = {};
|
|
20
|
+
__export(index_exports, {
|
|
21
21
|
CDN: () => CDN,
|
|
22
22
|
compareVersion: () => compareVersion,
|
|
23
23
|
decodeHTML: () => decodeHTML,
|
|
@@ -29,12 +29,9 @@ __export(src_exports, {
|
|
|
29
29
|
setObject: () => setObject,
|
|
30
30
|
splitColors: () => splitColors
|
|
31
31
|
});
|
|
32
|
-
module.exports = __toCommonJS(
|
|
32
|
+
module.exports = __toCommonJS(index_exports);
|
|
33
33
|
const CDN = "https://testingcf.jsdelivr.net";
|
|
34
|
-
|
|
35
|
-
if (typeof document === "object") {
|
|
36
|
-
textarea = document.createElement("textarea");
|
|
37
|
-
}
|
|
34
|
+
const textarea = /* @__PURE__ */ (() => typeof document === "object" ? document.createElement("textarea") : void 0)();
|
|
38
35
|
const decodeHTML = (str) => {
|
|
39
36
|
textarea.innerHTML = str;
|
|
40
37
|
return textarea.value;
|
package/dist/index.mjs
CHANGED
|
@@ -1,8 +1,5 @@
|
|
|
1
1
|
const CDN = "https://testingcf.jsdelivr.net";
|
|
2
|
-
|
|
3
|
-
if (typeof document === "object") {
|
|
4
|
-
textarea = document.createElement("textarea");
|
|
5
|
-
}
|
|
2
|
+
const textarea = /* @__PURE__ */ (() => typeof document === "object" ? document.createElement("textarea") : void 0)();
|
|
6
3
|
const decodeHTML = (str) => {
|
|
7
4
|
textarea.innerHTML = str;
|
|
8
5
|
return textarea.value;
|
package/eslintrc.cjs
CHANGED
|
@@ -615,6 +615,12 @@ module.exports = {
|
|
|
615
615
|
excludeTags: ['description'],
|
|
616
616
|
},
|
|
617
617
|
],
|
|
618
|
+
'jsdoc/check-param-names': [
|
|
619
|
+
1,
|
|
620
|
+
{
|
|
621
|
+
disableMissingParamChecks: true,
|
|
622
|
+
},
|
|
623
|
+
],
|
|
618
624
|
'jsdoc/check-tag-names': 1,
|
|
619
625
|
'jsdoc/check-types': 1,
|
|
620
626
|
'jsdoc/multiline-blocks': 1,
|
|
@@ -862,6 +868,7 @@ module.exports = {
|
|
|
862
868
|
allowAsThisParameter: true,
|
|
863
869
|
},
|
|
864
870
|
],
|
|
871
|
+
'@typescript-eslint/no-misused-spread': 2,
|
|
865
872
|
'@typescript-eslint/no-namespace': [
|
|
866
873
|
2,
|
|
867
874
|
{
|
package/package.json
CHANGED
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bhsd/common",
|
|
3
|
-
"version": "0.6.
|
|
3
|
+
"version": "0.6.5",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"author": "Bhsd",
|
|
6
6
|
"files": [
|
|
7
7
|
"/dist/",
|
|
8
|
-
"*.cjs"
|
|
8
|
+
"*.cjs",
|
|
9
|
+
"!.eslintrc.cjs"
|
|
9
10
|
],
|
|
10
11
|
"exports": {
|
|
11
12
|
".": {
|
|
@@ -17,36 +18,38 @@
|
|
|
17
18
|
"./package.json": "./package.json"
|
|
18
19
|
},
|
|
19
20
|
"types": "./dist/index.d.ts",
|
|
21
|
+
"sideEffects": false,
|
|
20
22
|
"bin": {
|
|
21
23
|
"copy-dev": "bin/dev.cjs"
|
|
22
24
|
},
|
|
23
25
|
"scripts": {
|
|
24
26
|
"prepublishOnly": "npm run build",
|
|
25
|
-
"build": "tsc --emitDeclarationOnly && esbuild src/index.ts --charset=utf8 --target=
|
|
27
|
+
"build": "tsc --emitDeclarationOnly && esbuild src/index.ts --charset=utf8 --target=es2024 --format=cjs --outfile=dist/index.js && esbuild src/index.ts --charset=utf8 --target=es2024 --format=esm --outfile=dist/index.mjs",
|
|
26
28
|
"lint:ts": "tsc --noEmit && eslint --cache .",
|
|
27
29
|
"lint": "npm run lint:ts"
|
|
28
30
|
},
|
|
29
31
|
"devDependencies": {
|
|
30
|
-
"@stylistic/eslint-plugin": "^
|
|
31
|
-
"@stylistic/stylelint-plugin": "^3.1.
|
|
32
|
+
"@stylistic/eslint-plugin": "^3.1.0",
|
|
33
|
+
"@stylistic/stylelint-plugin": "^3.1.2",
|
|
32
34
|
"@types/mocha": "^10.0.10",
|
|
33
|
-
"@
|
|
34
|
-
"@typescript-eslint/
|
|
35
|
-
"
|
|
35
|
+
"@types/node": "^22.13.1",
|
|
36
|
+
"@typescript-eslint/eslint-plugin": "^8.23.0",
|
|
37
|
+
"@typescript-eslint/parser": "^8.23.0",
|
|
38
|
+
"esbuild": "^0.25.0",
|
|
36
39
|
"eslint": "^8.57.1",
|
|
37
40
|
"eslint-plugin-es-x": "^8.4.1",
|
|
38
41
|
"eslint-plugin-eslint-comments": "^3.2.0",
|
|
39
|
-
"eslint-plugin-jsdoc": "^50.6.
|
|
42
|
+
"eslint-plugin-jsdoc": "^50.6.3",
|
|
40
43
|
"eslint-plugin-json-es": "^1.6.0",
|
|
41
44
|
"eslint-plugin-markdown": "4.0.1",
|
|
42
|
-
"eslint-plugin-n": "^17.
|
|
45
|
+
"eslint-plugin-n": "^17.15.1",
|
|
43
46
|
"eslint-plugin-promise": "^7.2.1",
|
|
44
|
-
"eslint-plugin-regexp": "^2.
|
|
47
|
+
"eslint-plugin-regexp": "^2.7.0",
|
|
45
48
|
"eslint-plugin-unicorn": "^56.0.1",
|
|
46
|
-
"http-server": "^14.1.
|
|
47
|
-
"mocha": "^
|
|
48
|
-
"stylelint": "^16.
|
|
49
|
-
"stylelint-config-recommended": "^
|
|
50
|
-
"typescript": "^5.7.
|
|
49
|
+
"http-server": "^14.1.1",
|
|
50
|
+
"mocha": "^11.1.0",
|
|
51
|
+
"stylelint": "^16.14.1",
|
|
52
|
+
"stylelint-config-recommended": "^15.0.0",
|
|
53
|
+
"typescript": "^5.7.3"
|
|
51
54
|
}
|
|
52
55
|
}
|