bananass 0.6.0 → 0.6.1

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.
@@ -1,8 +1,11 @@
1
+ /**
2
+ * @import { Problem } from "./types/index.js"
3
+ */
1
4
  /** @satisfies {number} */
2
5
  export const BAEKJOON_PROBLEM_NUMBER_MIN: 1000;
3
6
  /** @satisfies {string} */
4
7
  export const PKG_DESCRIPTION: string;
5
- /** @satisfies {string} */
8
+ /** @type {'bananass'} */
6
9
  export const PKG_NAME: "bananass";
7
10
  /** @satisfies {string} */
8
11
  export const PKG_VERSION: string;
@@ -23,7 +26,7 @@ export const URL_BOJ_MAIN: "https://www.acmicpc.net";
23
26
  export function URL_BOJ_PROBLEM(problem: Problem): string;
24
27
  /** @satisfies {string} */
25
28
  export const DEFAULT_ENTRY_DIR_NAME: "bananass";
26
- /** @satisfies {`.${name}`} */
29
+ /** @satisfies {'.bananass'} */
27
30
  export const DEFAULT_OUT_DIR_NAME: ".bananass";
28
31
  /** @satisfies {string} */
29
32
  export const DEFAULT_OUT_FILE_EXTENSION: ".cjs";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "bananass",
3
- "version": "0.6.0",
3
+ "version": "0.6.1",
4
4
  "type": "module",
5
5
  "description": "Baekjoon Framework for JavaScript.🍌",
6
6
  "exports": {
@@ -62,6 +62,7 @@
62
62
  "typescript"
63
63
  ],
64
64
  "author": "루밀LuMir <rpfos@naver.com> (https://github.com/lumirlumir)",
65
+ "funding": "https://github.com/sponsors/lumirlumir",
65
66
  "license": "MIT",
66
67
  "homepage": "https://bananass.lumir.page",
67
68
  "repository": {
@@ -90,17 +91,17 @@
90
91
  "@babel/core": "^7.29.0",
91
92
  "@babel/plugin-transform-modules-commonjs": "^7.28.6",
92
93
  "@babel/plugin-transform-typescript": "^7.28.6",
93
- "@babel/preset-env": "^7.29.0",
94
- "babel-loader": "^10.0.0",
95
- "bananass-utils-console": "^0.6.0",
96
- "commander": "^14.0.2",
97
- "defu": "^6.1.4",
98
- "enhanced-resolve": "^5.18.3",
94
+ "@babel/preset-env": "^7.29.2",
95
+ "babel-loader": "^10.1.1",
96
+ "bananass-utils-console": "^0.6.1",
97
+ "commander": "^14.0.3",
98
+ "defu": "^6.1.6",
99
+ "enhanced-resolve": "^5.20.1",
99
100
  "envinfo": "^7.21.0",
100
101
  "jiti": "^2.6.1",
101
102
  "open": "^10.2.0",
102
- "webpack": "^5.105.1",
103
- "zod": "^4.3.5"
103
+ "webpack": "^5.105.4",
104
+ "zod": "^4.3.6"
104
105
  },
105
106
  "devDependencies": {
106
107
  "@types/babel__core": "^7.20.5",
@@ -6,7 +6,7 @@
6
6
  // Import
7
7
  // --------------------------------------------------------------------------------
8
8
 
9
- import { createRequire } from 'node:module';
9
+ import pkg from '../../package.json' with { type: 'json' };
10
10
 
11
11
  // --------------------------------------------------------------------------------
12
12
  // Typedefs
@@ -16,15 +16,6 @@ import { createRequire } from 'node:module';
16
16
  * @import { Problem } from "./types/index.js"
17
17
  */
18
18
 
19
- // --------------------------------------------------------------------------------
20
- // Declaration
21
- // --------------------------------------------------------------------------------
22
-
23
- /** @type {{ description: string, homepage: string, name: 'bananass', version: string }} */
24
- const { description, homepage, name, version } = createRequire(import.meta.url)(
25
- '../../package.json',
26
- );
27
-
28
19
  // --------------------------------------------------------------------------------
29
20
  // Export
30
21
  // --------------------------------------------------------------------------------
@@ -42,16 +33,16 @@ export const BAEKJOON_PROBLEM_NUMBER_MIN = 1_000;
42
33
  // #region String
43
34
 
44
35
  /** @satisfies {string} */
45
- export const PKG_DESCRIPTION = description;
46
- /** @satisfies {string} */
47
- export const PKG_NAME = name;
36
+ export const PKG_DESCRIPTION = pkg.description;
37
+ /** @type {'bananass'} */
38
+ export const PKG_NAME = /** @type {'bananass'} */ (pkg.name);
48
39
  /** @satisfies {string} */
49
- export const PKG_VERSION = version;
40
+ export const PKG_VERSION = pkg.version;
50
41
  /** @satisfies {string} */
51
42
  export const PKG_AUTHOR = '루밀LuMir';
52
43
 
53
44
  /** @satisfies {string} */
54
- export const URL_HOMEPAGE = homepage;
45
+ export const URL_HOMEPAGE = pkg.homepage;
55
46
  /** @satisfies {string} */
56
47
  export const URL_NPM = 'https://www.npmjs.com';
57
48
  /** @satisfies {string} */
@@ -66,9 +57,9 @@ export const URL_BOJ_MAIN = 'https://www.acmicpc.net';
66
57
  export const URL_BOJ_PROBLEM = problem => `${URL_BOJ_MAIN}/problem/${problem}`;
67
58
 
68
59
  /** @satisfies {string} */
69
- export const DEFAULT_ENTRY_DIR_NAME = name;
70
- /** @satisfies {`.${name}`} */
71
- export const DEFAULT_OUT_DIR_NAME = `.${name}`;
60
+ export const DEFAULT_ENTRY_DIR_NAME = PKG_NAME;
61
+ /** @satisfies {'.bananass'} */
62
+ export const DEFAULT_OUT_DIR_NAME = `.${PKG_NAME}`;
72
63
  /** @satisfies {string} */
73
64
  export const DEFAULT_OUT_FILE_EXTENSION = '.cjs';
74
65