@alexlit/lint-kit 172.1.0 → 173.0.0

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.
Files changed (216) hide show
  1. package/package.json +1 -1
  2. package/packages/config-stylelint/package.json +9 -9
  3. package/scripts/i.sh +2 -0
  4. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/LICENSE +0 -21
  5. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/README.md +0 -54
  6. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/configs/base.d.ts +0 -23
  7. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/configs/base.js +0 -25
  8. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/configs/flat/base.d.ts +0 -35
  9. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/configs/flat/base.js +0 -35
  10. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/configs/flat/recommended.d.ts +0 -1194
  11. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/configs/flat/recommended.js +0 -39
  12. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/configs/recommended.d.ts +0 -29
  13. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/configs/recommended.js +0 -29
  14. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/index.d.ts +0 -2532
  15. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/index.js +0 -62
  16. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/key-format-style.d.ts +0 -2
  17. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/key-format-style.js +0 -247
  18. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-deprecated-i18n-component.d.ts +0 -2
  19. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-deprecated-i18n-component.js +0 -85
  20. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-deprecated-i18n-place-attr.d.ts +0 -2
  21. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-deprecated-i18n-place-attr.js +0 -41
  22. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-deprecated-i18n-places-prop.d.ts +0 -2
  23. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-deprecated-i18n-places-prop.js +0 -36
  24. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-deprecated-modulo-syntax.d.ts +0 -2
  25. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-deprecated-modulo-syntax.js +0 -94
  26. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-deprecated-tc.d.ts +0 -2
  27. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-deprecated-tc.js +0 -42
  28. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-deprecated-v-t.d.ts +0 -2
  29. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-deprecated-v-t.js +0 -33
  30. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-duplicate-keys-in-locale.d.ts +0 -2
  31. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-duplicate-keys-in-locale.js +0 -271
  32. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-dynamic-keys.d.ts +0 -2
  33. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-dynamic-keys.js +0 -105
  34. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-html-messages.d.ts +0 -2
  35. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-html-messages.js +0 -137
  36. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-i18n-t-path-prop.d.ts +0 -2
  37. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-i18n-t-path-prop.js +0 -44
  38. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-missing-keys-in-other-locales.d.ts +0 -2
  39. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-missing-keys-in-other-locales.js +0 -264
  40. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-missing-keys.d.ts +0 -2
  41. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-missing-keys.js +0 -111
  42. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-raw-text.d.ts +0 -2
  43. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-raw-text.js +0 -575
  44. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-unknown-locale.d.ts +0 -2
  45. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-unknown-locale.js +0 -198
  46. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-unused-keys.d.ts +0 -2
  47. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-unused-keys.js +0 -456
  48. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-v-html.d.ts +0 -2
  49. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/no-v-html.js +0 -50
  50. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/prefer-linked-key-with-paren.d.ts +0 -2
  51. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/prefer-linked-key-with-paren.js +0 -108
  52. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/prefer-sfc-lang-attr.d.ts +0 -2
  53. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/prefer-sfc-lang-attr.js +0 -58
  54. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/sfc-locale-attr.d.ts +0 -2
  55. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/sfc-locale-attr.js +0 -65
  56. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/valid-message-syntax.d.ts +0 -2
  57. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/rules/valid-message-syntax.js +0 -186
  58. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/types/eslint.d.ts +0 -216
  59. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/types/eslint.js +0 -2
  60. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/types/i18n.d.ts +0 -5
  61. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/types/i18n.js +0 -2
  62. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/types/index.d.ts +0 -6
  63. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/types/index.js +0 -22
  64. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/types/nodes.d.ts +0 -7
  65. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/types/nodes.js +0 -2
  66. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/types/settings.d.ts +0 -8
  67. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/types/settings.js +0 -2
  68. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/types/types.d.ts +0 -38
  69. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/types/types.js +0 -2
  70. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/types/vue-parser-services.d.ts +0 -32
  71. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/types/vue-parser-services.js +0 -2
  72. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/cache-function.d.ts +0 -2
  73. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/cache-function.js +0 -11
  74. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/cache-loader.d.ts +0 -10
  75. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/cache-loader.js +0 -27
  76. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/casing.d.ts +0 -10
  77. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/casing.js +0 -101
  78. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/collect-keys.d.ts +0 -13
  79. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/collect-keys.js +0 -160
  80. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/collect-linked-keys.d.ts +0 -2
  81. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/collect-linked-keys.js +0 -49
  82. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/compat.d.ts +0 -3
  83. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/compat.js +0 -35
  84. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/default-timeouts.d.ts +0 -6
  85. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/default-timeouts.js +0 -10
  86. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/get-cwd.d.ts +0 -2
  87. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/get-cwd.js +0 -9
  88. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/glob-utils.d.ts +0 -15
  89. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/glob-utils.js +0 -154
  90. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/ignored-paths.d.ts +0 -43
  91. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/ignored-paths.js +0 -234
  92. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/index.d.ts +0 -25
  93. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/index.js +0 -446
  94. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/key-path.d.ts +0 -2
  95. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/key-path.js +0 -27
  96. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/locale-messages.d.ts +0 -54
  97. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/locale-messages.js +0 -187
  98. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/message-compiler/parser-v9.d.ts +0 -8
  99. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/message-compiler/parser-v9.js +0 -40
  100. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/message-compiler/parser.d.ts +0 -5
  101. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/message-compiler/parser.js +0 -18
  102. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/message-compiler/traverser.d.ts +0 -6
  103. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/message-compiler/traverser.js +0 -31
  104. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/message-compiler/utils.d.ts +0 -28
  105. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/message-compiler/utils.js +0 -279
  106. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/parser-config-resolver/build-parser-using-flat-config.d.ts +0 -2
  107. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/parser-config-resolver/build-parser-using-flat-config.js +0 -11
  108. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/parser-config-resolver/build-parser-using-legacy-config.d.ts +0 -2
  109. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/parser-config-resolver/build-parser-using-legacy-config.js +0 -46
  110. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/parser-config-resolver/index.d.ts +0 -4
  111. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/parser-config-resolver/index.js +0 -18
  112. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/parser-config-resolver/parse-by-parser.d.ts +0 -3
  113. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/parser-config-resolver/parse-by-parser.js +0 -42
  114. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/parser-config-resolver/should-use-flat-config.d.ts +0 -2
  115. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/parser-config-resolver/should-use-flat-config.js +0 -54
  116. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/parser-config-resolver/worker.d.ts +0 -1
  117. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/parser-config-resolver/worker.js +0 -32
  118. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/parsers/index.d.ts +0 -4
  119. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/parsers/index.js +0 -32
  120. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/path-utils.d.ts +0 -2
  121. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/path-utils.js +0 -21
  122. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/regexp.d.ts +0 -1
  123. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/regexp.js +0 -16
  124. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/resource-loader.d.ts +0 -10
  125. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/resource-loader.js +0 -32
  126. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/rule.d.ts +0 -9
  127. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/dist/utils/rule.js +0 -75
  128. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/node_modules/globals/globals.json +0 -3345
  129. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/node_modules/globals/index.d.ts +0 -3452
  130. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/node_modules/globals/index.js +0 -2
  131. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/node_modules/globals/license +0 -9
  132. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/node_modules/globals/package.json +0 -117
  133. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/node_modules/globals/readme.md +0 -42
  134. package/packages/config-eslint/node_modules/@intlify/eslint-plugin-vue-i18n/package.json +0 -147
  135. package/packages/config-eslint/node_modules/glob/LICENSE +0 -15
  136. package/packages/config-eslint/node_modules/glob/README.md +0 -1265
  137. package/packages/config-eslint/node_modules/glob/dist/commonjs/glob.d.ts +0 -388
  138. package/packages/config-eslint/node_modules/glob/dist/commonjs/glob.d.ts.map +0 -1
  139. package/packages/config-eslint/node_modules/glob/dist/commonjs/glob.js +0 -247
  140. package/packages/config-eslint/node_modules/glob/dist/commonjs/glob.js.map +0 -1
  141. package/packages/config-eslint/node_modules/glob/dist/commonjs/has-magic.d.ts +0 -14
  142. package/packages/config-eslint/node_modules/glob/dist/commonjs/has-magic.d.ts.map +0 -1
  143. package/packages/config-eslint/node_modules/glob/dist/commonjs/has-magic.js +0 -27
  144. package/packages/config-eslint/node_modules/glob/dist/commonjs/has-magic.js.map +0 -1
  145. package/packages/config-eslint/node_modules/glob/dist/commonjs/ignore.d.ts +0 -24
  146. package/packages/config-eslint/node_modules/glob/dist/commonjs/ignore.d.ts.map +0 -1
  147. package/packages/config-eslint/node_modules/glob/dist/commonjs/ignore.js +0 -119
  148. package/packages/config-eslint/node_modules/glob/dist/commonjs/ignore.js.map +0 -1
  149. package/packages/config-eslint/node_modules/glob/dist/commonjs/index.d.ts +0 -97
  150. package/packages/config-eslint/node_modules/glob/dist/commonjs/index.d.ts.map +0 -1
  151. package/packages/config-eslint/node_modules/glob/dist/commonjs/index.js +0 -68
  152. package/packages/config-eslint/node_modules/glob/dist/commonjs/index.js.map +0 -1
  153. package/packages/config-eslint/node_modules/glob/dist/commonjs/package.json +0 -3
  154. package/packages/config-eslint/node_modules/glob/dist/commonjs/pattern.d.ts +0 -76
  155. package/packages/config-eslint/node_modules/glob/dist/commonjs/pattern.d.ts.map +0 -1
  156. package/packages/config-eslint/node_modules/glob/dist/commonjs/pattern.js +0 -219
  157. package/packages/config-eslint/node_modules/glob/dist/commonjs/pattern.js.map +0 -1
  158. package/packages/config-eslint/node_modules/glob/dist/commonjs/processor.d.ts +0 -59
  159. package/packages/config-eslint/node_modules/glob/dist/commonjs/processor.d.ts.map +0 -1
  160. package/packages/config-eslint/node_modules/glob/dist/commonjs/processor.js +0 -301
  161. package/packages/config-eslint/node_modules/glob/dist/commonjs/processor.js.map +0 -1
  162. package/packages/config-eslint/node_modules/glob/dist/commonjs/walker.d.ts +0 -97
  163. package/packages/config-eslint/node_modules/glob/dist/commonjs/walker.d.ts.map +0 -1
  164. package/packages/config-eslint/node_modules/glob/dist/commonjs/walker.js +0 -387
  165. package/packages/config-eslint/node_modules/glob/dist/commonjs/walker.js.map +0 -1
  166. package/packages/config-eslint/node_modules/glob/dist/esm/bin.d.mts +0 -3
  167. package/packages/config-eslint/node_modules/glob/dist/esm/bin.d.mts.map +0 -1
  168. package/packages/config-eslint/node_modules/glob/dist/esm/bin.mjs +0 -346
  169. package/packages/config-eslint/node_modules/glob/dist/esm/bin.mjs.map +0 -1
  170. package/packages/config-eslint/node_modules/glob/dist/esm/glob.d.ts +0 -388
  171. package/packages/config-eslint/node_modules/glob/dist/esm/glob.d.ts.map +0 -1
  172. package/packages/config-eslint/node_modules/glob/dist/esm/glob.js +0 -243
  173. package/packages/config-eslint/node_modules/glob/dist/esm/glob.js.map +0 -1
  174. package/packages/config-eslint/node_modules/glob/dist/esm/has-magic.d.ts +0 -14
  175. package/packages/config-eslint/node_modules/glob/dist/esm/has-magic.d.ts.map +0 -1
  176. package/packages/config-eslint/node_modules/glob/dist/esm/has-magic.js +0 -23
  177. package/packages/config-eslint/node_modules/glob/dist/esm/has-magic.js.map +0 -1
  178. package/packages/config-eslint/node_modules/glob/dist/esm/ignore.d.ts +0 -24
  179. package/packages/config-eslint/node_modules/glob/dist/esm/ignore.d.ts.map +0 -1
  180. package/packages/config-eslint/node_modules/glob/dist/esm/ignore.js +0 -115
  181. package/packages/config-eslint/node_modules/glob/dist/esm/ignore.js.map +0 -1
  182. package/packages/config-eslint/node_modules/glob/dist/esm/index.d.ts +0 -97
  183. package/packages/config-eslint/node_modules/glob/dist/esm/index.d.ts.map +0 -1
  184. package/packages/config-eslint/node_modules/glob/dist/esm/index.js +0 -55
  185. package/packages/config-eslint/node_modules/glob/dist/esm/index.js.map +0 -1
  186. package/packages/config-eslint/node_modules/glob/dist/esm/package.json +0 -3
  187. package/packages/config-eslint/node_modules/glob/dist/esm/pattern.d.ts +0 -76
  188. package/packages/config-eslint/node_modules/glob/dist/esm/pattern.d.ts.map +0 -1
  189. package/packages/config-eslint/node_modules/glob/dist/esm/pattern.js +0 -215
  190. package/packages/config-eslint/node_modules/glob/dist/esm/pattern.js.map +0 -1
  191. package/packages/config-eslint/node_modules/glob/dist/esm/processor.d.ts +0 -59
  192. package/packages/config-eslint/node_modules/glob/dist/esm/processor.d.ts.map +0 -1
  193. package/packages/config-eslint/node_modules/glob/dist/esm/processor.js +0 -294
  194. package/packages/config-eslint/node_modules/glob/dist/esm/processor.js.map +0 -1
  195. package/packages/config-eslint/node_modules/glob/dist/esm/walker.d.ts +0 -97
  196. package/packages/config-eslint/node_modules/glob/dist/esm/walker.d.ts.map +0 -1
  197. package/packages/config-eslint/node_modules/glob/dist/esm/walker.js +0 -381
  198. package/packages/config-eslint/node_modules/glob/dist/esm/walker.js.map +0 -1
  199. package/packages/config-eslint/node_modules/glob/package.json +0 -99
  200. package/packages/config-eslint/node_modules/ignore/LICENSE-MIT +0 -21
  201. package/packages/config-eslint/node_modules/ignore/README.md +0 -452
  202. package/packages/config-eslint/node_modules/ignore/index.d.ts +0 -81
  203. package/packages/config-eslint/node_modules/ignore/index.js +0 -784
  204. package/packages/config-eslint/node_modules/ignore/legacy.js +0 -681
  205. package/packages/config-eslint/node_modules/ignore/package.json +0 -87
  206. package/packages/config-eslint/node_modules/synckit/LICENSE +0 -21
  207. package/packages/config-eslint/node_modules/synckit/README.md +0 -245
  208. package/packages/config-eslint/node_modules/synckit/index.d.cts +0 -3
  209. package/packages/config-eslint/node_modules/synckit/lib/index.cjs +0 -590
  210. package/packages/config-eslint/node_modules/synckit/lib/index.d.ts +0 -43
  211. package/packages/config-eslint/node_modules/synckit/lib/index.js +0 -476
  212. package/packages/config-eslint/node_modules/synckit/lib/index.js.map +0 -1
  213. package/packages/config-eslint/node_modules/synckit/lib/types.d.ts +0 -40
  214. package/packages/config-eslint/node_modules/synckit/lib/types.js +0 -2
  215. package/packages/config-eslint/node_modules/synckit/lib/types.js.map +0 -1
  216. package/packages/config-eslint/node_modules/synckit/package.json +0 -46
@@ -1,590 +0,0 @@
1
- 'use strict';
2
-
3
- var node_crypto = require('node:crypto');
4
- var fs = require('node:fs');
5
- var module$1 = require('node:module');
6
- var path = require('node:path');
7
- var node_url = require('node:url');
8
- var node_worker_threads = require('node:worker_threads');
9
- var core = require('@pkgr/core');
10
-
11
- var __defProp = Object.defineProperty;
12
- var __getOwnPropSymbols = Object.getOwnPropertySymbols;
13
- var __hasOwnProp = Object.prototype.hasOwnProperty;
14
- var __propIsEnum = Object.prototype.propertyIsEnumerable;
15
- var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
16
- var __spreadValues = (a, b) => {
17
- for (var prop in b || (b = {}))
18
- if (__hasOwnProp.call(b, prop))
19
- __defNormalProp(a, prop, b[prop]);
20
- if (__getOwnPropSymbols)
21
- for (var prop of __getOwnPropSymbols(b)) {
22
- if (__propIsEnum.call(b, prop))
23
- __defNormalProp(a, prop, b[prop]);
24
- }
25
- return a;
26
- };
27
- var __objRest = (source, exclude) => {
28
- var target = {};
29
- for (var prop in source)
30
- if (__hasOwnProp.call(source, prop) && exclude.indexOf(prop) < 0)
31
- target[prop] = source[prop];
32
- if (source != null && __getOwnPropSymbols)
33
- for (var prop of __getOwnPropSymbols(source)) {
34
- if (exclude.indexOf(prop) < 0 && __propIsEnum.call(source, prop))
35
- target[prop] = source[prop];
36
- }
37
- return target;
38
- };
39
- var __async = (__this, __arguments, generator) => {
40
- return new Promise((resolve, reject) => {
41
- var fulfilled = (value) => {
42
- try {
43
- step(generator.next(value));
44
- } catch (e) {
45
- reject(e);
46
- }
47
- };
48
- var rejected = (value) => {
49
- try {
50
- step(generator.throw(value));
51
- } catch (e) {
52
- reject(e);
53
- }
54
- };
55
- var step = (x) => x.done ? resolve(x.value) : Promise.resolve(x.value).then(fulfilled, rejected);
56
- step((generator = generator.apply(__this, __arguments)).next());
57
- });
58
- };
59
- const import_meta = {};
60
- const INT32_BYTES = 4;
61
- const TsRunner = {
62
- // https://nodejs.org/docs/latest/api/typescript.html#type-stripping
63
- Node: "node",
64
- // https://bun.sh/docs/typescript
65
- Bun: "bun",
66
- // https://github.com/TypeStrong/ts-node
67
- TsNode: "ts-node",
68
- // https://github.com/egoist/esbuild-register
69
- EsbuildRegister: "esbuild-register",
70
- // https://github.com/folke/esbuild-runner
71
- EsbuildRunner: "esbuild-runner",
72
- // https://github.com/swc-project/swc-node/tree/master/packages/register
73
- SWC: "swc",
74
- // https://github.com/esbuild-kit/tsx
75
- TSX: "tsx"
76
- };
77
- const {
78
- NODE_OPTIONS: NODE_OPTIONS_ = "",
79
- SYNCKIT_EXEC_ARGV = "",
80
- SYNCKIT_GLOBAL_SHIMS,
81
- SYNCKIT_TIMEOUT,
82
- SYNCKIT_TS_RUNNER
83
- } = process.env;
84
- const MTS_SUPPORTED_NODE_VERSION = "16";
85
- const LOADER_SUPPORTED_NODE_VERSION = "20";
86
- const STRIP_TYPES_NODE_VERSION = "22.6";
87
- const TRANSFORM_TYPES_NODE_VERSION = "22.7";
88
- const FEATURE_TYPESCRIPT_NODE_VERSION = "22.10";
89
- const DEFAULT_TYPES_NODE_VERSION = "23.6";
90
- const STRIP_TYPES_FLAG = "--experimental-strip-types";
91
- const TRANSFORM_TYPES_FLAG = "--experimental-transform-types";
92
- const NO_STRIP_TYPES_FLAG = "--no-experimental-strip-types";
93
- const NODE_OPTIONS = NODE_OPTIONS_.split(/\s+/);
94
- const hasFlag = (flag) => NODE_OPTIONS.includes(flag) || process.argv.includes(flag);
95
- const parseVersion = (version) => version.split(".").map(Number.parseFloat);
96
- const compareVersion = (version1, version2) => {
97
- const versions1 = parseVersion(version1);
98
- const versions2 = parseVersion(version2);
99
- const length = Math.max(versions1.length, versions2.length);
100
- for (let i = 0; i < length; i++) {
101
- const v1 = versions1[i] || 0;
102
- const v2 = versions2[i] || 0;
103
- if (v1 > v2) {
104
- return 1;
105
- }
106
- if (v1 < v2) {
107
- return -1;
108
- }
109
- }
110
- return 0;
111
- };
112
- const NODE_VERSION = process.versions.node;
113
- const NO_STRIP_TYPES = (
114
- // >=
115
- compareVersion(NODE_VERSION, FEATURE_TYPESCRIPT_NODE_VERSION) >= 0 ? process.features.typescript === false : hasFlag(NO_STRIP_TYPES_FLAG) && !hasFlag(STRIP_TYPES_FLAG) && !hasFlag(TRANSFORM_TYPES_FLAG)
116
- );
117
- const DEFAULT_TIMEOUT = SYNCKIT_TIMEOUT ? +SYNCKIT_TIMEOUT : void 0;
118
- const DEFAULT_EXEC_ARGV = SYNCKIT_EXEC_ARGV.split(",");
119
- const DEFAULT_TS_RUNNER = SYNCKIT_TS_RUNNER;
120
- const DEFAULT_GLOBAL_SHIMS = ["1", "true"].includes(
121
- SYNCKIT_GLOBAL_SHIMS
122
- );
123
- const DEFAULT_GLOBAL_SHIMS_PRESET = [
124
- {
125
- moduleName: "node-fetch",
126
- globalName: "fetch"
127
- },
128
- {
129
- moduleName: "node:perf_hooks",
130
- globalName: "performance",
131
- named: "performance"
132
- }
133
- ];
134
- let syncFnCache;
135
- function extractProperties(object) {
136
- if (object && typeof object === "object") {
137
- const properties = {};
138
- for (const key in object) {
139
- properties[key] = object[key];
140
- }
141
- return properties;
142
- }
143
- }
144
- function createSyncFn(workerPath, timeoutOrOptions) {
145
- syncFnCache != null ? syncFnCache : syncFnCache = /* @__PURE__ */ new Map();
146
- if (typeof workerPath !== "string" || workerPath.startsWith("file://")) {
147
- workerPath = node_url.fileURLToPath(workerPath);
148
- }
149
- const cachedSyncFn = syncFnCache.get(workerPath);
150
- if (cachedSyncFn) {
151
- return cachedSyncFn;
152
- }
153
- if (!path.isAbsolute(workerPath)) {
154
- throw new Error("`workerPath` must be absolute");
155
- }
156
- const syncFn = startWorkerThread(
157
- workerPath,
158
- /* istanbul ignore next */
159
- typeof timeoutOrOptions === "number" ? { timeout: timeoutOrOptions } : timeoutOrOptions
160
- );
161
- syncFnCache.set(workerPath, syncFn);
162
- return syncFn;
163
- }
164
- const dataUrl = (code) => new URL(`data:text/javascript,${encodeURIComponent(code)}`);
165
- const isFile = (path2) => {
166
- var _a;
167
- try {
168
- return !!((_a = fs.statSync(path2, { throwIfNoEntry: false })) == null ? void 0 : _a.isFile());
169
- } catch (e) {
170
- return false;
171
- }
172
- };
173
- const setupTsRunner = (workerPath, { execArgv, tsRunner }) => {
174
- let ext = path.extname(workerPath);
175
- if (!/([/\\])node_modules\1/.test(workerPath) && (!ext || /^\.[cm]?js$/.test(ext))) {
176
- const workPathWithoutExt = ext ? workerPath.slice(0, -ext.length) : workerPath;
177
- let extensions;
178
- switch (ext) {
179
- case ".cjs": {
180
- extensions = [".cts", ".cjs"];
181
- break;
182
- }
183
- case ".mjs": {
184
- extensions = [".mts", ".mjs"];
185
- break;
186
- }
187
- default: {
188
- extensions = [".ts", ".js"];
189
- break;
190
- }
191
- }
192
- const found = core.tryExtensions(workPathWithoutExt, extensions);
193
- let differentExt;
194
- if (found && (!ext || (differentExt = found !== workPathWithoutExt))) {
195
- workerPath = found;
196
- if (differentExt) {
197
- ext = path.extname(workerPath);
198
- }
199
- }
200
- }
201
- const isTs = /\.[cm]?ts$/.test(workerPath);
202
- let jsUseEsm = workerPath.endsWith(".mjs");
203
- let tsUseEsm = workerPath.endsWith(".mts");
204
- if (isTs) {
205
- if (!tsUseEsm) {
206
- const pkg = core.findUp(workerPath);
207
- if (pkg) {
208
- tsUseEsm = core.cjsRequire(pkg).type === "module";
209
- }
210
- }
211
- const stripTypesIndex = execArgv.indexOf(STRIP_TYPES_FLAG);
212
- const transformTypesIndex = execArgv.indexOf(TRANSFORM_TYPES_FLAG);
213
- const noStripTypesIndex = execArgv.indexOf(NO_STRIP_TYPES_FLAG);
214
- const execArgvNoStripTypes = noStripTypesIndex > stripTypesIndex || noStripTypesIndex > transformTypesIndex;
215
- const noStripTypes = execArgvNoStripTypes || stripTypesIndex === -1 && transformTypesIndex === -1 && NO_STRIP_TYPES;
216
- if (tsRunner == null) {
217
- if (process.versions.bun) {
218
- tsRunner = TsRunner.Bun;
219
- } else if (!noStripTypes && // >=
220
- compareVersion(NODE_VERSION, STRIP_TYPES_NODE_VERSION) >= 0) {
221
- tsRunner = TsRunner.Node;
222
- } else if (core.isPkgAvailable(TsRunner.TsNode)) {
223
- tsRunner = TsRunner.TsNode;
224
- }
225
- }
226
- switch (tsRunner) {
227
- case TsRunner.Bun: {
228
- break;
229
- }
230
- case TsRunner.Node: {
231
- if (compareVersion(NODE_VERSION, STRIP_TYPES_NODE_VERSION) < 0) {
232
- throw new Error(
233
- "type stripping is not supported in this node version"
234
- );
235
- }
236
- if (noStripTypes) {
237
- throw new Error("type stripping is disabled explicitly");
238
- }
239
- if (compareVersion(NODE_VERSION, DEFAULT_TYPES_NODE_VERSION) >= 0) {
240
- break;
241
- }
242
- if (
243
- // >=
244
- compareVersion(NODE_VERSION, TRANSFORM_TYPES_NODE_VERSION) >= 0 && !execArgv.includes(TRANSFORM_TYPES_FLAG)
245
- ) {
246
- execArgv = [TRANSFORM_TYPES_FLAG, ...execArgv];
247
- } else if (
248
- // >=
249
- compareVersion(NODE_VERSION, STRIP_TYPES_NODE_VERSION) >= 0 && !execArgv.includes(STRIP_TYPES_FLAG)
250
- ) {
251
- execArgv = [STRIP_TYPES_FLAG, ...execArgv];
252
- }
253
- break;
254
- }
255
- case TsRunner.TsNode: {
256
- if (tsUseEsm) {
257
- if (!execArgv.includes("--loader")) {
258
- execArgv = ["--loader", `${TsRunner.TsNode}/esm`, ...execArgv];
259
- }
260
- } else if (!execArgv.includes("-r")) {
261
- execArgv = ["-r", `${TsRunner.TsNode}/register`, ...execArgv];
262
- }
263
- break;
264
- }
265
- case TsRunner.EsbuildRegister: {
266
- if (!execArgv.includes("-r")) {
267
- execArgv = ["-r", TsRunner.EsbuildRegister, ...execArgv];
268
- }
269
- break;
270
- }
271
- case TsRunner.EsbuildRunner: {
272
- if (!execArgv.includes("-r")) {
273
- execArgv = ["-r", `${TsRunner.EsbuildRunner}/register`, ...execArgv];
274
- }
275
- break;
276
- }
277
- case TsRunner.SWC: {
278
- if (!execArgv.includes("-r")) {
279
- execArgv = ["-r", `@${TsRunner.SWC}-node/register`, ...execArgv];
280
- }
281
- break;
282
- }
283
- case TsRunner.TSX: {
284
- if (!execArgv.includes("--loader")) {
285
- execArgv = ["--loader", TsRunner.TSX, ...execArgv];
286
- }
287
- break;
288
- }
289
- default: {
290
- throw new Error(`Unknown ts runner: ${String(tsRunner)}`);
291
- }
292
- }
293
- } else if (!jsUseEsm) {
294
- const pkg = core.findUp(workerPath);
295
- if (pkg) {
296
- jsUseEsm = core.cjsRequire(pkg).type === "module";
297
- }
298
- }
299
- let resolvedPnpLoaderPath;
300
- if (process.versions.pnp) {
301
- let pnpApiPath;
302
- try {
303
- pnpApiPath = core.cjsRequire.resolve("pnpapi");
304
- } catch (e) {
305
- }
306
- if (pnpApiPath && !NODE_OPTIONS.some(
307
- (option, index) => ["-r", "--require"].includes(option) && pnpApiPath === core.cjsRequire.resolve(NODE_OPTIONS[index + 1])
308
- ) && !execArgv.includes(pnpApiPath)) {
309
- execArgv = ["-r", pnpApiPath, ...execArgv];
310
- const pnpLoaderPath = path.resolve(pnpApiPath, "../.pnp.loader.mjs");
311
- if (isFile(pnpLoaderPath)) {
312
- resolvedPnpLoaderPath = node_url.pathToFileURL(pnpLoaderPath).toString();
313
- if (compareVersion(NODE_VERSION, LOADER_SUPPORTED_NODE_VERSION) < 0) {
314
- execArgv = [
315
- "--experimental-loader",
316
- resolvedPnpLoaderPath,
317
- ...execArgv
318
- ];
319
- }
320
- }
321
- }
322
- }
323
- return {
324
- ext,
325
- isTs,
326
- jsUseEsm,
327
- tsRunner,
328
- tsUseEsm,
329
- workerPath,
330
- pnpLoaderPath: resolvedPnpLoaderPath,
331
- execArgv
332
- };
333
- };
334
- const md5Hash = (text) => (
335
- // eslint-disable-next-line sonarjs/hashing
336
- node_crypto.createHash("md5").update(text).digest("hex")
337
- );
338
- const encodeImportModule = (moduleNameOrGlobalShim, type = "import") => {
339
- const { moduleName, globalName, named, conditional } = typeof moduleNameOrGlobalShim === "string" ? { moduleName: moduleNameOrGlobalShim } : moduleNameOrGlobalShim;
340
- const importStatement = type === "import" ? `import${globalName ? " " + (named === null ? "* as " + globalName : (named == null ? void 0 : named.trim()) ? `{${named}}` : globalName) + " from" : ""} '${path.isAbsolute(moduleName) ? String(node_url.pathToFileURL(moduleName)) : moduleName}'` : `${globalName ? "const " + ((named == null ? void 0 : named.trim()) ? `{${named}}` : globalName) + "=" : ""}require('${moduleName.replace(/\\/g, "\\\\")}')`;
341
- if (!globalName) {
342
- return importStatement;
343
- }
344
- const overrideStatement = `globalThis.${globalName}=${(named == null ? void 0 : named.trim()) ? named : globalName}`;
345
- return importStatement + (conditional === false ? `;${overrideStatement}` : `;if(!globalThis.${globalName})${overrideStatement}`);
346
- };
347
- const _generateGlobals = (globalShims, type) => globalShims.reduce(
348
- (acc, shim) => `${acc}${acc ? ";" : ""}${encodeImportModule(shim, type)}`,
349
- ""
350
- );
351
- let globalsCache;
352
- let tmpdir;
353
- const _dirname = typeof __dirname === "undefined" ? path.dirname(node_url.fileURLToPath(import_meta.url)) : (
354
- /* istanbul ignore next */
355
- __dirname
356
- );
357
- let sharedBuffer;
358
- let sharedBufferView;
359
- const generateGlobals = (workerPath, globalShims, type = "import") => {
360
- if (globalShims.length === 0) {
361
- return "";
362
- }
363
- globalsCache != null ? globalsCache : globalsCache = /* @__PURE__ */ new Map();
364
- const cached = globalsCache.get(workerPath);
365
- if (cached) {
366
- const [content2, filepath2] = cached;
367
- if (type === "require" && !filepath2 || type === "import" && filepath2 && isFile(filepath2)) {
368
- return content2;
369
- }
370
- }
371
- const globals = _generateGlobals(globalShims, type);
372
- let content = globals;
373
- let filepath;
374
- if (type === "import") {
375
- if (!tmpdir) {
376
- tmpdir = path.resolve(core.findUp(_dirname), "../node_modules/.synckit");
377
- }
378
- fs.mkdirSync(tmpdir, { recursive: true });
379
- filepath = path.resolve(tmpdir, md5Hash(workerPath) + ".mjs");
380
- content = encodeImportModule(filepath);
381
- fs.writeFileSync(filepath, globals);
382
- }
383
- globalsCache.set(workerPath, [content, filepath]);
384
- return content;
385
- };
386
- function startWorkerThread(workerPath, {
387
- timeout = DEFAULT_TIMEOUT,
388
- execArgv = DEFAULT_EXEC_ARGV,
389
- tsRunner = DEFAULT_TS_RUNNER,
390
- transferList = [],
391
- globalShims = DEFAULT_GLOBAL_SHIMS
392
- } = {}) {
393
- const { port1: mainPort, port2: workerPort } = new node_worker_threads.MessageChannel();
394
- const {
395
- isTs,
396
- ext,
397
- jsUseEsm,
398
- tsUseEsm,
399
- tsRunner: finalTsRunner,
400
- workerPath: finalWorkerPath,
401
- pnpLoaderPath,
402
- execArgv: finalExecArgv
403
- } = setupTsRunner(workerPath, { execArgv, tsRunner });
404
- const workerPathUrl = node_url.pathToFileURL(finalWorkerPath);
405
- if (/\.[cm]ts$/.test(finalWorkerPath)) {
406
- const isTsxSupported = !tsUseEsm || // >=
407
- compareVersion(NODE_VERSION, MTS_SUPPORTED_NODE_VERSION) >= 0;
408
- if (!finalTsRunner) {
409
- throw new Error("No ts runner specified, ts worker path is not supported");
410
- } else if ([
411
- // https://github.com/egoist/esbuild-register/issues/79
412
- TsRunner.EsbuildRegister,
413
- // https://github.com/folke/esbuild-runner/issues/67
414
- TsRunner.EsbuildRunner,
415
- // https://github.com/swc-project/swc-node/issues/667
416
- TsRunner.SWC,
417
- .../* istanbul ignore next */
418
- isTsxSupported ? [] : [TsRunner.TSX]
419
- ].includes(finalTsRunner)) {
420
- throw new Error(
421
- `${finalTsRunner} is not supported for ${ext} files yet` + /* istanbul ignore next */
422
- (isTsxSupported ? ", you can try [tsx](https://github.com/esbuild-kit/tsx) instead" : "")
423
- );
424
- }
425
- }
426
- const finalGlobalShims = (globalShims === true ? DEFAULT_GLOBAL_SHIMS_PRESET : Array.isArray(globalShims) ? globalShims : []).filter(({ moduleName }) => core.isPkgAvailable(moduleName));
427
- sharedBufferView != null ? sharedBufferView : sharedBufferView = new Int32Array(
428
- /* istanbul ignore next */
429
- sharedBuffer != null ? sharedBuffer : sharedBuffer = new SharedArrayBuffer(
430
- INT32_BYTES
431
- ),
432
- 0,
433
- 1
434
- );
435
- const useGlobals = finalGlobalShims.length > 0;
436
- const useEval = isTs ? !tsUseEsm : !jsUseEsm && useGlobals;
437
- const worker = new node_worker_threads.Worker(
438
- jsUseEsm && useGlobals || tsUseEsm && finalTsRunner === TsRunner.TsNode ? dataUrl(
439
- `${generateGlobals(
440
- finalWorkerPath,
441
- finalGlobalShims
442
- )};import '${String(workerPathUrl)}'`
443
- ) : useEval ? `${generateGlobals(
444
- finalWorkerPath,
445
- finalGlobalShims,
446
- "require"
447
- )};${encodeImportModule(finalWorkerPath, "require")}` : workerPathUrl,
448
- {
449
- eval: useEval,
450
- workerData: { sharedBufferView, workerPort, pnpLoaderPath },
451
- transferList: [workerPort, ...transferList],
452
- execArgv: finalExecArgv
453
- }
454
- );
455
- let nextID = 0;
456
- const receiveMessageWithId = (port, expectedId, waitingTimeout) => {
457
- const start = Date.now();
458
- const status = Atomics.wait(sharedBufferView, 0, 0, waitingTimeout);
459
- Atomics.store(sharedBufferView, 0, 0);
460
- if (!["ok", "not-equal"].includes(status)) {
461
- const abortMsg = {
462
- id: expectedId,
463
- cmd: "abort"
464
- };
465
- port.postMessage(abortMsg);
466
- throw new Error("Internal error: Atomics.wait() failed: " + status);
467
- }
468
- const result = node_worker_threads.receiveMessageOnPort(mainPort);
469
- const msg = result == null ? void 0 : result.message;
470
- if ((msg == null ? void 0 : msg.id) == null || msg.id < expectedId) {
471
- const waitingTime = Date.now() - start;
472
- return receiveMessageWithId(
473
- port,
474
- expectedId,
475
- waitingTimeout ? waitingTimeout - waitingTime : void 0
476
- );
477
- }
478
- const _a = msg, { id } = _a, message = __objRest(_a, ["id"]);
479
- if (expectedId !== id) {
480
- throw new Error(
481
- `Internal error: Expected id ${expectedId} but got id ${id}`
482
- );
483
- }
484
- return __spreadValues({ id }, message);
485
- };
486
- const syncFn = (...args) => {
487
- const id = nextID++;
488
- const msg = { id, args };
489
- worker.postMessage(msg);
490
- const { result, error, properties, stdio } = receiveMessageWithId(
491
- mainPort,
492
- id,
493
- timeout
494
- );
495
- for (const { type, chunk, encoding } of stdio) {
496
- process[type].write(chunk, encoding);
497
- }
498
- if (error) {
499
- throw Object.assign(error, properties);
500
- }
501
- return result;
502
- };
503
- worker.unref();
504
- return syncFn;
505
- }
506
- function runAsWorker(fn) {
507
- if (!node_worker_threads.workerData) {
508
- return;
509
- }
510
- const stdio = [];
511
- for (const type of ["stdout", "stderr"]) {
512
- process[type]._writev = (chunks, callback) => {
513
- for (const {
514
- // type-coverage:ignore-next-line -- we can't control
515
- chunk,
516
- encoding
517
- } of chunks) {
518
- stdio.push({
519
- type,
520
- // eslint-disable-next-line @typescript-eslint/no-unsafe-assignment -- we can't control
521
- chunk,
522
- encoding
523
- });
524
- }
525
- callback();
526
- };
527
- }
528
- const { workerPort, sharedBufferView: sharedBufferView2, pnpLoaderPath } = node_worker_threads.workerData;
529
- if (pnpLoaderPath && // >=
530
- compareVersion(NODE_VERSION, LOADER_SUPPORTED_NODE_VERSION) >= 0) {
531
- module$1.register(pnpLoaderPath);
532
- }
533
- node_worker_threads.parentPort.on(
534
- "message",
535
- ({ id, args }) => {
536
- (() => __async(this, null, function* () {
537
- let isAborted = false;
538
- const handleAbortMessage = (msg2) => {
539
- if (msg2.id === id && msg2.cmd === "abort") {
540
- isAborted = true;
541
- }
542
- };
543
- workerPort.on("message", handleAbortMessage);
544
- let msg;
545
- try {
546
- msg = { id, stdio, result: yield fn(...args) };
547
- } catch (error) {
548
- msg = { id, stdio, error, properties: extractProperties(error) };
549
- }
550
- workerPort.off("message", handleAbortMessage);
551
- if (isAborted) {
552
- stdio.length = 0;
553
- return;
554
- }
555
- try {
556
- workerPort.postMessage(msg);
557
- Atomics.add(sharedBufferView2, 0, 1);
558
- Atomics.notify(sharedBufferView2, 0);
559
- } finally {
560
- stdio.length = 0;
561
- }
562
- }))();
563
- }
564
- );
565
- }
566
-
567
- exports.DEFAULT_EXEC_ARGV = DEFAULT_EXEC_ARGV;
568
- exports.DEFAULT_GLOBAL_SHIMS = DEFAULT_GLOBAL_SHIMS;
569
- exports.DEFAULT_GLOBAL_SHIMS_PRESET = DEFAULT_GLOBAL_SHIMS_PRESET;
570
- exports.DEFAULT_TIMEOUT = DEFAULT_TIMEOUT;
571
- exports.DEFAULT_TS_RUNNER = DEFAULT_TS_RUNNER;
572
- exports.DEFAULT_TYPES_NODE_VERSION = DEFAULT_TYPES_NODE_VERSION;
573
- exports.FEATURE_TYPESCRIPT_NODE_VERSION = FEATURE_TYPESCRIPT_NODE_VERSION;
574
- exports.LOADER_SUPPORTED_NODE_VERSION = LOADER_SUPPORTED_NODE_VERSION;
575
- exports.MTS_SUPPORTED_NODE_VERSION = MTS_SUPPORTED_NODE_VERSION;
576
- exports.NODE_VERSION = NODE_VERSION;
577
- exports.NO_STRIP_TYPES_FLAG = NO_STRIP_TYPES_FLAG;
578
- exports.STRIP_TYPES_FLAG = STRIP_TYPES_FLAG;
579
- exports.STRIP_TYPES_NODE_VERSION = STRIP_TYPES_NODE_VERSION;
580
- exports.TRANSFORM_TYPES_FLAG = TRANSFORM_TYPES_FLAG;
581
- exports.TRANSFORM_TYPES_NODE_VERSION = TRANSFORM_TYPES_NODE_VERSION;
582
- exports.TsRunner = TsRunner;
583
- exports._generateGlobals = _generateGlobals;
584
- exports.compareVersion = compareVersion;
585
- exports.createSyncFn = createSyncFn;
586
- exports.encodeImportModule = encodeImportModule;
587
- exports.extractProperties = extractProperties;
588
- exports.generateGlobals = generateGlobals;
589
- exports.isFile = isFile;
590
- exports.runAsWorker = runAsWorker;
@@ -1,43 +0,0 @@
1
- import { type TransferListItem } from 'node:worker_threads';
2
- import type { AnyFn, GlobalShim, Syncify, ValueOf } from './types.js';
3
- export * from './types.js';
4
- export declare const TsRunner: {
5
- readonly Node: "node";
6
- readonly Bun: "bun";
7
- readonly TsNode: "ts-node";
8
- readonly EsbuildRegister: "esbuild-register";
9
- readonly EsbuildRunner: "esbuild-runner";
10
- readonly SWC: "swc";
11
- readonly TSX: "tsx";
12
- };
13
- export type TsRunner = ValueOf<typeof TsRunner>;
14
- export declare const MTS_SUPPORTED_NODE_VERSION = "16";
15
- export declare const LOADER_SUPPORTED_NODE_VERSION = "20";
16
- export declare const STRIP_TYPES_NODE_VERSION = "22.6";
17
- export declare const TRANSFORM_TYPES_NODE_VERSION = "22.7";
18
- export declare const FEATURE_TYPESCRIPT_NODE_VERSION = "22.10";
19
- export declare const DEFAULT_TYPES_NODE_VERSION = "23.6";
20
- export declare const STRIP_TYPES_FLAG = "--experimental-strip-types";
21
- export declare const TRANSFORM_TYPES_FLAG = "--experimental-transform-types";
22
- export declare const NO_STRIP_TYPES_FLAG = "--no-experimental-strip-types";
23
- export declare const compareVersion: (version1: string, version2: string) => 1 | -1 | 0;
24
- export declare const NODE_VERSION: string;
25
- export declare const DEFAULT_TIMEOUT: number | undefined;
26
- export declare const DEFAULT_EXEC_ARGV: string[];
27
- export declare const DEFAULT_TS_RUNNER: TsRunner | undefined;
28
- export declare const DEFAULT_GLOBAL_SHIMS: boolean;
29
- export declare const DEFAULT_GLOBAL_SHIMS_PRESET: GlobalShim[];
30
- export interface SynckitOptions {
31
- execArgv?: string[];
32
- globalShims?: GlobalShim[] | boolean;
33
- timeout?: number;
34
- transferList?: TransferListItem[];
35
- tsRunner?: TsRunner;
36
- }
37
- export declare function extractProperties<T extends object>(object: T): T;
38
- export declare function extractProperties<T>(object?: T): T | undefined;
39
- export declare function createSyncFn<T extends AnyFn>(workerPath: URL | string, timeoutOrOptions?: SynckitOptions | number): Syncify<T>;
40
- export declare const isFile: (path: string) => boolean;
41
- export declare const encodeImportModule: (moduleNameOrGlobalShim: GlobalShim | string, type?: "import" | "require") => string;
42
- export declare const generateGlobals: (workerPath: string, globalShims: GlobalShim[], type?: "import" | "require") => string;
43
- export declare function runAsWorker<T extends AnyFn<Promise<R> | R>, R = ReturnType<T>>(fn: T): void;