args-tokens 0.3.1 → 0.3.2

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.
@@ -73,5 +73,5 @@ export declare function isShortOption(arg: string): boolean;
73
73
  * @param arg the argument to check
74
74
  * @returns whether `arg` is a long option prefix
75
75
  */
76
- export declare function hasLongOptionPrefix(arg: string): number | false;
76
+ export declare function hasLongOptionPrefix(arg: string): boolean;
77
77
  export {};
package/lib/cjs/parser.js CHANGED
@@ -217,6 +217,7 @@ function isLongOptionAndValue(arg) {
217
217
  * @returns whether `arg` is a long option prefix
218
218
  */
219
219
  function hasLongOptionPrefix(arg) {
220
+ // @ts-ignore -- NOTE: `~` is a bitwise NOT operator
220
221
  return arg.length > 2 && ~arg.indexOf(LONG_OPTION_PREFIX);
221
222
  }
222
223
  /**
@@ -73,5 +73,5 @@ export declare function isShortOption(arg: string): boolean;
73
73
  * @param arg the argument to check
74
74
  * @returns whether `arg` is a long option prefix
75
75
  */
76
- export declare function hasLongOptionPrefix(arg: string): number | false;
76
+ export declare function hasLongOptionPrefix(arg: string): boolean;
77
77
  export {};
package/lib/esm/parser.js CHANGED
@@ -212,6 +212,7 @@ function isLongOptionAndValue(arg) {
212
212
  * @returns whether `arg` is a long option prefix
213
213
  */
214
214
  export function hasLongOptionPrefix(arg) {
215
+ // @ts-ignore -- NOTE: `~` is a bitwise NOT operator
215
216
  return arg.length > 2 && ~arg.indexOf(LONG_OPTION_PREFIX);
216
217
  }
217
218
  /**
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "args-tokens",
3
3
  "description": "parseArgs tokens compatibility and more high-performance parser",
4
- "version": "0.3.1",
4
+ "version": "0.3.2",
5
5
  "author": {
6
6
  "name": "kazuya kawaguchi",
7
7
  "email": "kawakazu80@gmail.com"
@@ -81,6 +81,7 @@
81
81
  "eslint-plugin-unicorn": "^56.0.1",
82
82
  "eslint-plugin-yml": "^1.16.0",
83
83
  "gh-changelogen": "^0.2.8",
84
+ "jsr": "^0.13.3",
84
85
  "knip": "^5.44.0",
85
86
  "lint-staged": "^15.4.3",
86
87
  "mitata": "^1.0.34",
@@ -119,6 +120,7 @@
119
120
  "fix:prettier": "prettier . --write",
120
121
  "lint": "pnpm run --parallel --color \"/^lint:/\"",
121
122
  "lint:eslint": "eslint .",
123
+ "lint:jsr": "jsr publish --dry-run --allow-dirty",
122
124
  "lint:knip": "knip",
123
125
  "lint:prettier": "prettier . --check",
124
126
  "release": "bumpp --commit \"release: v%s\" --all --push --tag",