@jsse/eslint-config 0.5.0 → 0.5.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.
package/dist/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { n as __exportAll, r as __toESM, t as __commonJSMin } from "./chunk-CdeBBKNj.js";
2
- import { n as DEBUG, r as SLOW_RULES, t as VERSION } from "./version-OtVn-Q4t.js";
2
+ import { n as DEBUG, r as SLOW_RULES, t as VERSION } from "./version-BMOOQznP.js";
3
3
  import { builtinModules, createRequire } from "node:module";
4
4
  import process$1 from "node:process";
5
5
  import fs, { promises, realpathSync, statSync } from "node:fs";
@@ -26,7 +26,7 @@ import eslintjs from "@eslint/js";
26
26
  import { mergeProcessors, processorPassThrough } from "eslint-merge-processors";
27
27
  import tseslint from "typescript-eslint";
28
28
 
29
- //#region node_modules/.pnpm/acorn@8.15.0/node_modules/acorn/dist/acorn.mjs
29
+ //#region node_modules/.pnpm/acorn@8.16.0/node_modules/acorn/dist/acorn.mjs
30
30
  var astralIdentifierCodes = [
31
31
  509,
32
32
  0,
@@ -58,8 +58,8 @@ var astralIdentifierCodes = [
58
58
  4,
59
59
  318,
60
60
  1,
61
- 80,
62
- 3,
61
+ 78,
62
+ 5,
63
63
  71,
64
64
  10,
65
65
  50,
@@ -204,7 +204,9 @@ var astralIdentifierCodes = [
204
204
  10,
205
205
  47,
206
206
  15,
207
- 343,
207
+ 199,
208
+ 7,
209
+ 137,
208
210
  9,
209
211
  54,
210
212
  7,
@@ -236,7 +238,9 @@ var astralIdentifierCodes = [
236
238
  4,
237
239
  9,
238
240
  9,
239
- 330,
241
+ 55,
242
+ 9,
243
+ 266,
240
244
  3,
241
245
  10,
242
246
  1,
@@ -336,7 +340,15 @@ var astralIdentifierCodes = [
336
340
  1,
337
341
  2,
338
342
  9,
339
- 726,
343
+ 233,
344
+ 0,
345
+ 3,
346
+ 0,
347
+ 8,
348
+ 1,
349
+ 6,
350
+ 0,
351
+ 475,
340
352
  6,
341
353
  110,
342
354
  6,
@@ -446,7 +458,9 @@ var astralIdentifierStartCodes = [
446
458
  21,
447
459
  11,
448
460
  25,
449
- 71,
461
+ 7,
462
+ 25,
463
+ 39,
450
464
  55,
451
465
  7,
452
466
  1,
@@ -491,8 +505,8 @@ var astralIdentifierStartCodes = [
491
505
  7,
492
506
  1,
493
507
  17,
494
- 2,
495
- 60,
508
+ 5,
509
+ 57,
496
510
  28,
497
511
  11,
498
512
  0,
@@ -676,7 +690,9 @@ var astralIdentifierStartCodes = [
676
690
  31,
677
691
  15,
678
692
  0,
679
- 328,
693
+ 24,
694
+ 43,
695
+ 261,
680
696
  18,
681
697
  16,
682
698
  0,
@@ -724,7 +740,11 @@ var astralIdentifierStartCodes = [
724
740
  44,
725
741
  212,
726
742
  63,
727
- 129,
743
+ 33,
744
+ 24,
745
+ 3,
746
+ 24,
747
+ 45,
728
748
  74,
729
749
  6,
730
750
  0,
@@ -734,13 +754,15 @@ var astralIdentifierStartCodes = [
734
754
  1,
735
755
  2,
736
756
  0,
737
- 29,
738
- 6135,
739
- 9,
740
- 1237,
757
+ 15,
758
+ 4,
759
+ 10,
760
+ 7381,
741
761
  42,
742
- 9,
743
- 8936,
762
+ 31,
763
+ 98,
764
+ 114,
765
+ 8702,
744
766
  3,
745
767
  2,
746
768
  6,
@@ -848,7 +870,19 @@ var astralIdentifierStartCodes = [
848
870
  29,
849
871
  3,
850
872
  0,
851
- 496,
873
+ 208,
874
+ 30,
875
+ 2,
876
+ 2,
877
+ 2,
878
+ 1,
879
+ 2,
880
+ 6,
881
+ 3,
882
+ 4,
883
+ 10,
884
+ 1,
885
+ 225,
852
886
  6,
853
887
  2,
854
888
  3,
@@ -931,12 +965,10 @@ var astralIdentifierStartCodes = [
931
965
  4421,
932
966
  42719,
933
967
  33,
934
- 4153,
935
- 7,
936
- 221,
968
+ 4381,
969
+ 3,
970
+ 5773,
937
971
  3,
938
- 5761,
939
- 15,
940
972
  7472,
941
973
  16,
942
974
  621,
@@ -945,10 +977,10 @@ var astralIdentifierStartCodes = [
945
977
  1507,
946
978
  4938,
947
979
  6,
948
- 4191
980
+ 8489
949
981
  ];
950
- var nonASCIIidentifierChars = "‌‍·̀-ͯ·҃-֑҇-ׇֽֿׁׂׅׄؐ-ًؚ-٩ٰۖ-ۜ۟-۪ۤۧۨ-ۭ۰-۹ܑܰ-݊ަ-ް߀-߉߫-߽߳ࠖ-࠙ࠛ-ࠣࠥ-ࠧࠩ-࡙࠭-࡛ࢗ-࢟࣊-ࣣ࣡-ःऺ-़ा-ॏ॑-ॗॢॣ०-९ঁ-ঃ়া-ৄেৈো-্ৗৢৣ০-৯৾ਁ-ਃ਼ਾ-ੂੇੈੋ-੍ੑ੦-ੱੵઁ-ઃ઼ા-ૅે-ૉો-્ૢૣ૦-૯ૺ-૿ଁ-ଃ଼ା-ୄେୈୋ-୍୕-ୗୢୣ୦-୯ஂா-ூெ-ைொ-்ௗ௦-௯ఀ-ఄ఼ా-ౄె-ైొ-్ౕౖౢౣ౦-౯ಁ-ಃ಼ಾ-ೄೆ-ೈೊ-್ೕೖೢೣ೦-೯ೳഀ-ഃ഻഼ാ-ൄെ-ൈൊ-്ൗൢൣ൦-൯ඁ-ඃ්ා-ුූෘ-ෟ෦-෯ෲෳัิ-ฺ็-๎๐-๙ັິ-ຼ່-໎໐-໙༘༙༠-༩༹༵༷༾༿ཱ-྄྆྇ྍ-ྗྙ-ྼ࿆ါ-ှ၀-၉ၖ-ၙၞ-ၠၢ-ၤၧ-ၭၱ-ၴႂ-ႍႏ-ႝ፝-፟፩-፱ᜒ-᜕ᜲ-᜴ᝒᝓᝲᝳ឴-៓៝០-៩᠋-᠍᠏-᠙ᢩᤠ-ᤫᤰ-᤻᥆-᥏᧐-᧚ᨗ-ᨛᩕ-ᩞ᩠-᩿᩼-᪉᪐-᪙᪰-᪽ᪿ-ᫎᬀ-ᬄ᬴-᭄᭐-᭙᭫-᭳ᮀ-ᮂᮡ-ᮭ᮰-᮹᯦-᯳ᰤ-᰷᱀-᱉᱐-᱙᳐-᳔᳒-᳨᳭᳴᳷-᳹᷀-᷿‌‍‿⁀⁔⃐-⃥⃜⃡-⃰⳯-⵿⳱ⷠ-〪ⷿ-゙゚〯・꘠-꘩꙯ꙴ-꙽ꚞꚟ꛰꛱ꠂ꠆ꠋꠣ-ꠧ꠬ꢀꢁꢴ-ꣅ꣐-꣙꣠-꣱ꣿ-꤉ꤦ-꤭ꥇ-꥓ꦀ-ꦃ꦳-꧀꧐-꧙ꧥ꧰-꧹ꨩ-ꨶꩃꩌꩍ꩐-꩙ꩻ-ꩽꪰꪲ-ꪴꪷꪸꪾ꪿꫁ꫫ-ꫯꫵ꫶ꯣ-ꯪ꯬꯭꯰-꯹ﬞ︀-️︠-︯︳︴﹍-﹏0-9_・";
951
- var nonASCIIidentifierStartChars = "ªµºÀ-ÖØ-öø-ˁˆ-ˑˠ-ˤˬˮͰ-ʹͶͷͺ-ͽͿΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁҊ-ԯԱ-Ֆՙՠ-ֈא-תׯ-ײؠ-يٮٯٱ-ۓەۥۦۮۯۺ-ۼۿܐܒ-ܯݍ-ޥޱߊ-ߪߴߵߺࠀ-ࠕࠚࠤࠨࡀ-ࡘࡠ-ࡪࡰ-ࢇࢉ-ࢎࢠ-ࣉऄ-हऽॐक़-ॡॱ-ঀঅ-ঌএঐও-নপ-রলশ-হঽৎড়ঢ়য়-ৡৰৱৼਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹਖ਼-ੜਫ਼ੲ-ੴઅ-ઍએ-ઑઓ-નપ-રલળવ-હઽૐૠૡૹଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହଽଡ଼ଢ଼ୟ-ୡୱஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹௐఅ-ఌఎ-ఐఒ-నప-హఽౘ-ౚౝౠౡಀಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹಽೝೞೠೡೱೲഄ-ഌഎ-ഐഒ-ഺഽൎൔ-ൖൟ-ൡൺ-ൿඅ-ඖක-නඳ-රලව-ෆก-ะาำเ-ๆກຂຄຆ-ຊຌ-ຣລວ-ະາຳຽເ-ໄໆໜ-ໟༀཀ-ཇཉ-ཬྈ-ྌက-ဪဿၐ-ၕၚ-ၝၡၥၦၮ-ၰၵ-ႁႎႠ-ჅჇჍა-ჺჼ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚᎀ-ᎏᎠ-Ᏽᏸ-ᏽᐁ-ᙬᙯ-ᙿᚁ-ᚚᚠ-ᛪᛮ-ᛸᜀ-ᜑᜟ-ᜱᝀ-ᝑᝠ-ᝬᝮ-ᝰក-ឳៗៜᠠ-ᡸᢀ-ᢨᢪᢰ-ᣵᤀ-ᤞᥐ-ᥭᥰ-ᥴᦀ-ᦫᦰ-ᧉᨀ-ᨖᨠ-ᩔᪧᬅ-ᬳᭅ-ᭌᮃ-ᮠᮮᮯᮺ-ᯥᰀ-ᰣᱍ-ᱏᱚ-ᱽᲀ-ᲊᲐ-ᲺᲽ-Ჿᳩ-ᳬᳮ-ᳳᳵᳶᳺᴀ-ᶿḀ-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼⁱⁿₐ-ₜℂℇℊ-ℓℕ℘-ℝℤΩℨK-ℹℼ-ℿⅅ-ⅉⅎⅠ-ↈⰀ-ⳤⳫ-ⳮⳲⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯⶀ-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞ々-〇〡-〩〱-〵〸-〼ぁ-ゖ゛-ゟァ-ヺー-ヿㄅ-ㄯㄱ-ㆎㆠ-ㆿㇰ-ㇿ㐀-䶿一-ꒌꓐ-ꓽꔀ-ꘌꘐ-ꘟꘪꘫꙀ-ꙮꙿ-ꚝꚠ-ꛯꜗ-ꜟꜢ-ꞈꞋ-ꟍꟐꟑꟓꟕ-Ƛꟲ-ꠁꠃ-ꠅꠇ-ꠊꠌ-ꠢꡀ-ꡳꢂ-ꢳꣲ-ꣷꣻꣽꣾꤊ-ꤥꤰ-ꥆꥠ-ꥼꦄ-ꦲꧏꧠ-ꧤꧦ-ꧯꧺ-ꧾꨀ-ꨨꩀ-ꩂꩄ-ꩋꩠ-ꩶꩺꩾ-ꪯꪱꪵꪶꪹ-ꪽꫀꫂꫛ-ꫝꫠ-ꫪꫲ-ꫴꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꬰ-ꭚꭜ-ꭩꭰ-ꯢ가-힣ힰ-ퟆퟋ-ퟻ豈-舘並-龎ff-stﬓ-ﬗיִײַ-ﬨשׁ-זּטּ-לּמּנּסּףּפּצּ-ﮱﯓ-ﴽﵐ-ﶏﶒ-ﷇﷰ-ﷻﹰ-ﹴﹶ-ﻼA-Za-zヲ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ";
982
+ var nonASCIIidentifierChars = "‌‍·̀-ͯ·҃-֑҇-ׇֽֿׁׂׅׄؐ-ًؚ-٩ٰۖ-ۜ۟-۪ۤۧۨ-ۭ۰-۹ܑܰ-݊ަ-ް߀-߉߫-߽߳ࠖ-࠙ࠛ-ࠣࠥ-ࠧࠩ-࡙࠭-࡛ࢗ-࢟࣊-ࣣ࣡-ःऺ-़ा-ॏ॑-ॗॢॣ०-९ঁ-ঃ়া-ৄেৈো-্ৗৢৣ০-৯৾ਁ-ਃ਼ਾ-ੂੇੈੋ-੍ੑ੦-ੱੵઁ-ઃ઼ા-ૅે-ૉો-્ૢૣ૦-૯ૺ-૿ଁ-ଃ଼ା-ୄେୈୋ-୍୕-ୗୢୣ୦-୯ஂா-ூெ-ைொ-்ௗ௦-௯ఀ-ఄ఼ా-ౄె-ైొ-్ౕౖౢౣ౦-౯ಁ-ಃ಼ಾ-ೄೆ-ೈೊ-್ೕೖೢೣ೦-೯ೳഀ-ഃ഻഼ാ-ൄെ-ൈൊ-്ൗൢൣ൦-൯ඁ-ඃ්ා-ුූෘ-ෟ෦-෯ෲෳัิ-ฺ็-๎๐-๙ັິ-ຼ່-໎໐-໙༘༙༠-༩༹༵༷༾༿ཱ-྄྆྇ྍ-ྗྙ-ྼ࿆ါ-ှ၀-၉ၖ-ၙၞ-ၠၢ-ၤၧ-ၭၱ-ၴႂ-ႍႏ-ႝ፝-፟፩-፱ᜒ-᜕ᜲ-᜴ᝒᝓᝲᝳ឴-៓៝០-៩᠋-᠍᠏-᠙ᢩᤠ-ᤫᤰ-᤻᥆-᥏᧐-᧚ᨗ-ᨛᩕ-ᩞ᩠-᩿᩼-᪉᪐-᪙᪰-᪽ᪿ-᫝᫠-᫫ᬀ-ᬄ᬴-᭄᭐-᭙᭫-᭳ᮀ-ᮂᮡ-ᮭ᮰-᮹᯦-᯳ᰤ-᰷᱀-᱉᱐-᱙᳐-᳔᳒-᳨᳭᳴᳷-᳹᷀-᷿‌‍‿⁀⁔⃐-⃥⃜⃡-⃰⳯-⵿⳱ⷠ-〪ⷿ-゙゚〯・꘠-꘩꙯ꙴ-꙽ꚞꚟ꛰꛱ꠂ꠆ꠋꠣ-ꠧ꠬ꢀꢁꢴ-ꣅ꣐-꣙꣠-꣱ꣿ-꤉ꤦ-꤭ꥇ-꥓ꦀ-ꦃ꦳-꧀꧐-꧙ꧥ꧰-꧹ꨩ-ꨶꩃꩌꩍ꩐-꩙ꩻ-ꩽꪰꪲ-ꪴꪷꪸꪾ꪿꫁ꫫ-ꫯꫵ꫶ꯣ-ꯪ꯬꯭꯰-꯹ﬞ︀-️︠-︯︳︴﹍-﹏0-9_・";
983
+ var nonASCIIidentifierStartChars = "ªµºÀ-ÖØ-öø-ˁˆ-ˑˠ-ˤˬˮͰ-ʹͶͷͺ-ͽͿΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁҊ-ԯԱ-Ֆՙՠ-ֈא-תׯ-ײؠ-يٮٯٱ-ۓەۥۦۮۯۺ-ۼۿܐܒ-ܯݍ-ޥޱߊ-ߪߴߵߺࠀ-ࠕࠚࠤࠨࡀ-ࡘࡠ-ࡪࡰ-ࢇࢉ-࢏ࢠ-ࣉऄ-हऽॐक़-ॡॱ-ঀঅ-ঌএঐও-নপ-রলশ-হঽৎড়ঢ়য়-ৡৰৱৼਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹਖ਼-ੜਫ਼ੲ-ੴઅ-ઍએ-ઑઓ-નપ-રલળવ-હઽૐૠૡૹଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହଽଡ଼ଢ଼ୟ-ୡୱஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹௐఅ-ఌఎ-ఐఒ-నప-హఽౘ-ౚ౜ౝౠౡಀಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹಽ೜-ೞೠೡೱೲഄ-ഌഎ-ഐഒ-ഺഽൎൔ-ൖൟ-ൡൺ-ൿඅ-ඖක-නඳ-රලව-ෆก-ะาำเ-ๆກຂຄຆ-ຊຌ-ຣລວ-ະາຳຽເ-ໄໆໜ-ໟༀཀ-ཇཉ-ཬྈ-ྌက-ဪဿၐ-ၕၚ-ၝၡၥၦၮ-ၰၵ-ႁႎႠ-ჅჇჍა-ჺჼ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚᎀ-ᎏᎠ-Ᏽᏸ-ᏽᐁ-ᙬᙯ-ᙿᚁ-ᚚᚠ-ᛪᛮ-ᛸᜀ-ᜑᜟ-ᜱᝀ-ᝑᝠ-ᝬᝮ-ᝰក-ឳៗៜᠠ-ᡸᢀ-ᢨᢪᢰ-ᣵᤀ-ᤞᥐ-ᥭᥰ-ᥴᦀ-ᦫᦰ-ᧉᨀ-ᨖᨠ-ᩔᪧᬅ-ᬳᭅ-ᭌᮃ-ᮠᮮᮯᮺ-ᯥᰀ-ᰣᱍ-ᱏᱚ-ᱽᲀ-ᲊᲐ-ᲺᲽ-Ჿᳩ-ᳬᳮ-ᳳᳵᳶᳺᴀ-ᶿḀ-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼⁱⁿₐ-ₜℂℇℊ-ℓℕ℘-ℝℤΩℨK-ℹℼ-ℿⅅ-ⅉⅎⅠ-ↈⰀ-ⳤⳫ-ⳮⳲⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯⶀ-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞ々-〇〡-〩〱-〵〸-〼ぁ-ゖ゛-ゟァ-ヺー-ヿㄅ-ㄯㄱ-ㆎㆠ-ㆿㇰ-ㇿ㐀-䶿一-ꒌꓐ-ꓽꔀ-ꘌꘐ-ꘟꘪꘫꙀ-ꙮꙿ-ꚝꚠ-ꛯꜗ-ꜟꜢ-ꞈꞋ-Ƛ꟱-ꠁꠃ-ꠅꠇ-ꠊꠌ-ꠢꡀ-ꡳꢂ-ꢳꣲ-ꣷꣻꣽꣾꤊ-ꤥꤰ-ꥆꥠ-ꥼꦄ-ꦲꧏꧠ-ꧤꧦ-ꧯꧺ-ꧾꨀ-ꨨꩀ-ꩂꩄ-ꩋꩠ-ꩶꩺꩾ-ꪯꪱꪵꪶꪹ-ꪽꫀꫂꫛ-ꫝꫠ-ꫪꫲ-ꫴꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꬰ-ꭚꭜ-ꭩꭰ-ꯢ가-힣ힰ-ퟆퟋ-ퟻ豈-舘並-龎ff-stﬓ-ﬗיִײַ-ﬨשׁ-זּטּ-לּמּנּסּףּפּצּ-ﮱﯓ-ﴽﵐ-ﶏﶒ-ﷇﷰ-ﷻﹰ-ﹴﹶ-ﻼA-Za-zヲ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ";
952
984
  var reservedWords = {
953
985
  3: "abstract boolean byte char class double enum export extends final float goto implements import int interface long native package private protected public short static super synchronized throws transient volatile",
954
986
  5: "class enum extends super const export import",
@@ -1302,6 +1334,9 @@ function getOptions(opts) {
1302
1334
  if (isArray(options.onComment)) {
1303
1335
  options.onComment = pushComment(options, options.onComment);
1304
1336
  }
1337
+ if (options.sourceType === "commonjs" && options.allowAwaitOutsideFunction) {
1338
+ throw new Error("Cannot use allowAwaitOutsideFunction with sourceType: commonjs");
1339
+ }
1305
1340
  return options;
1306
1341
  }
1307
1342
  function pushComment(options, array) {
@@ -1321,7 +1356,7 @@ function pushComment(options, array) {
1321
1356
  array.push(comment);
1322
1357
  };
1323
1358
  }
1324
- var SCOPE_TOP = 1, SCOPE_FUNCTION = 2, SCOPE_ASYNC = 4, SCOPE_GENERATOR = 8, SCOPE_ARROW = 16, SCOPE_SIMPLE_CATCH = 32, SCOPE_SUPER = 64, SCOPE_DIRECT_SUPER = 128, SCOPE_CLASS_STATIC_BLOCK = 256, SCOPE_CLASS_FIELD_INIT = 512, SCOPE_VAR = SCOPE_TOP | SCOPE_FUNCTION | SCOPE_CLASS_STATIC_BLOCK;
1359
+ var SCOPE_TOP = 1, SCOPE_FUNCTION = 2, SCOPE_ASYNC = 4, SCOPE_GENERATOR = 8, SCOPE_ARROW = 16, SCOPE_SIMPLE_CATCH = 32, SCOPE_SUPER = 64, SCOPE_DIRECT_SUPER = 128, SCOPE_CLASS_STATIC_BLOCK = 256, SCOPE_CLASS_FIELD_INIT = 512, SCOPE_SWITCH = 1024, SCOPE_VAR = SCOPE_TOP | SCOPE_FUNCTION | SCOPE_CLASS_STATIC_BLOCK;
1325
1360
  function functionFlags(async, generator) {
1326
1361
  return SCOPE_FUNCTION | (async ? SCOPE_ASYNC : 0) | (generator ? SCOPE_GENERATOR : 0);
1327
1362
  }
@@ -1370,7 +1405,7 @@ var Parser = function Parser(options, input, startPos) {
1370
1405
  this.skipLineComment(2);
1371
1406
  }
1372
1407
  this.scopeStack = [];
1373
- this.enterScope(SCOPE_TOP);
1408
+ this.enterScope(this.options.sourceType === "commonjs" ? SCOPE_FUNCTION : SCOPE_TOP);
1374
1409
  this.regexpState = null;
1375
1410
  this.privateNameStack = [];
1376
1411
  };
@@ -1379,10 +1414,12 @@ var prototypeAccessors = {
1379
1414
  inGenerator: { configurable: true },
1380
1415
  inAsync: { configurable: true },
1381
1416
  canAwait: { configurable: true },
1417
+ allowReturn: { configurable: true },
1382
1418
  allowSuper: { configurable: true },
1383
1419
  allowDirectSuper: { configurable: true },
1384
1420
  treatFunctionsAsVar: { configurable: true },
1385
1421
  allowNewDotTarget: { configurable: true },
1422
+ allowUsing: { configurable: true },
1386
1423
  inClassStaticBlock: { configurable: true }
1387
1424
  };
1388
1425
  Parser.prototype.parse = function parse() {
@@ -1412,6 +1449,15 @@ prototypeAccessors.canAwait.get = function() {
1412
1449
  }
1413
1450
  return this.inModule && this.options.ecmaVersion >= 13 || this.options.allowAwaitOutsideFunction;
1414
1451
  };
1452
+ prototypeAccessors.allowReturn.get = function() {
1453
+ if (this.inFunction) {
1454
+ return true;
1455
+ }
1456
+ if (this.options.allowReturnOutsideFunction && this.currentVarScope().flags & SCOPE_TOP) {
1457
+ return true;
1458
+ }
1459
+ return false;
1460
+ };
1415
1461
  prototypeAccessors.allowSuper.get = function() {
1416
1462
  var ref = this.currentThisScope();
1417
1463
  var flags = ref.flags;
@@ -1433,6 +1479,17 @@ prototypeAccessors.allowNewDotTarget.get = function() {
1433
1479
  }
1434
1480
  return false;
1435
1481
  };
1482
+ prototypeAccessors.allowUsing.get = function() {
1483
+ var ref = this.currentScope();
1484
+ var flags = ref.flags;
1485
+ if (flags & SCOPE_SWITCH) {
1486
+ return false;
1487
+ }
1488
+ if (!this.inModule && flags & SCOPE_TOP) {
1489
+ return false;
1490
+ }
1491
+ return true;
1492
+ };
1436
1493
  prototypeAccessors.inClassStaticBlock.get = function() {
1437
1494
  return (this.currentVarScope().flags & SCOPE_CLASS_STATIC_BLOCK) > 0;
1438
1495
  };
@@ -1603,7 +1660,7 @@ pp$8.parseTopLevel = function(node) {
1603
1660
  }
1604
1661
  this.adaptDirectivePrologue(node.body);
1605
1662
  this.next();
1606
- node.sourceType = this.options.sourceType;
1663
+ node.sourceType = this.options.sourceType === "commonjs" ? "script" : this.options.sourceType;
1607
1664
  return this.finishNode(node, "Program");
1608
1665
  };
1609
1666
  var loopLabel = { kind: "loop" }, switchLabel = { kind: "switch" };
@@ -1613,25 +1670,25 @@ pp$8.isLet = function(context) {
1613
1670
  }
1614
1671
  skipWhiteSpace.lastIndex = this.pos;
1615
1672
  var skip = skipWhiteSpace.exec(this.input);
1616
- var next = this.pos + skip[0].length, nextCh = this.input.charCodeAt(next);
1673
+ var next = this.pos + skip[0].length, nextCh = this.fullCharCodeAt(next);
1617
1674
  if (nextCh === 91 || nextCh === 92) {
1618
1675
  return true;
1619
1676
  }
1620
1677
  if (context) {
1621
1678
  return false;
1622
1679
  }
1623
- if (nextCh === 123 || nextCh > 55295 && nextCh < 56320) {
1680
+ if (nextCh === 123) {
1624
1681
  return true;
1625
1682
  }
1626
- if (isIdentifierStart(nextCh, true)) {
1627
- var pos = next + 1;
1628
- while (isIdentifierChar(nextCh = this.input.charCodeAt(pos), true)) {
1629
- ++pos;
1630
- }
1631
- if (nextCh === 92 || nextCh > 55295 && nextCh < 56320) {
1683
+ if (isIdentifierStart(nextCh)) {
1684
+ var start = next;
1685
+ do {
1686
+ next += nextCh <= 65535 ? 1 : 2;
1687
+ } while (isIdentifierChar(nextCh = this.fullCharCodeAt(next)));
1688
+ if (nextCh === 92) {
1632
1689
  return true;
1633
1690
  }
1634
- var ident = this.input.slice(next, pos);
1691
+ var ident = this.input.slice(start, next);
1635
1692
  if (!keywordRelationalOperator.test(ident)) {
1636
1693
  return true;
1637
1694
  }
@@ -1645,7 +1702,7 @@ pp$8.isAsyncFunction = function() {
1645
1702
  skipWhiteSpace.lastIndex = this.pos;
1646
1703
  var skip = skipWhiteSpace.exec(this.input);
1647
1704
  var next = this.pos + skip[0].length, after;
1648
- return !lineBreak.test(this.input.slice(this.pos, next)) && this.input.slice(next, next + 8) === "function" && (next + 8 === this.input.length || !(isIdentifierChar(after = this.input.charCodeAt(next + 8)) || after > 55295 && after < 56320));
1705
+ return !lineBreak.test(this.input.slice(this.pos, next)) && this.input.slice(next, next + 8) === "function" && (next + 8 === this.input.length || !(isIdentifierChar(after = this.fullCharCodeAt(next + 8)) || after === 92));
1649
1706
  };
1650
1707
  pp$8.isUsingKeyword = function(isAwaitUsing, isFor) {
1651
1708
  if (this.options.ecmaVersion < 17 || !this.isContextual(isAwaitUsing ? "await" : "using")) {
@@ -1658,26 +1715,33 @@ pp$8.isUsingKeyword = function(isAwaitUsing, isFor) {
1658
1715
  return false;
1659
1716
  }
1660
1717
  if (isAwaitUsing) {
1661
- var awaitEndPos = next + 5, after;
1662
- if (this.input.slice(next, awaitEndPos) !== "using" || awaitEndPos === this.input.length || isIdentifierChar(after = this.input.charCodeAt(awaitEndPos)) || after > 55295 && after < 56320) {
1718
+ var usingEndPos = next + 5, after;
1719
+ if (this.input.slice(next, usingEndPos) !== "using" || usingEndPos === this.input.length || isIdentifierChar(after = this.fullCharCodeAt(usingEndPos)) || after === 92) {
1663
1720
  return false;
1664
1721
  }
1665
- skipWhiteSpace.lastIndex = awaitEndPos;
1722
+ skipWhiteSpace.lastIndex = usingEndPos;
1666
1723
  var skipAfterUsing = skipWhiteSpace.exec(this.input);
1667
- if (skipAfterUsing && lineBreak.test(this.input.slice(awaitEndPos, awaitEndPos + skipAfterUsing[0].length))) {
1724
+ next = usingEndPos + skipAfterUsing[0].length;
1725
+ if (skipAfterUsing && lineBreak.test(this.input.slice(usingEndPos, next))) {
1668
1726
  return false;
1669
1727
  }
1670
1728
  }
1671
- if (isFor) {
1672
- var ofEndPos = next + 2, after$1;
1673
- if (this.input.slice(next, ofEndPos) === "of") {
1674
- if (ofEndPos === this.input.length || !isIdentifierChar(after$1 = this.input.charCodeAt(ofEndPos)) && !(after$1 > 55295 && after$1 < 56320)) {
1675
- return false;
1676
- }
1677
- }
1729
+ var ch = this.fullCharCodeAt(next);
1730
+ if (!isIdentifierStart(ch) && ch !== 92) {
1731
+ return false;
1678
1732
  }
1679
- var ch = this.input.charCodeAt(next);
1680
- return isIdentifierStart(ch, true) || ch === 92;
1733
+ var idStart = next;
1734
+ do {
1735
+ next += ch <= 65535 ? 1 : 2;
1736
+ } while (isIdentifierChar(ch = this.fullCharCodeAt(next)));
1737
+ if (ch === 92) {
1738
+ return true;
1739
+ }
1740
+ var id = this.input.slice(idStart, next);
1741
+ if (keywordRelationalOperator.test(id) || isFor && id === "of") {
1742
+ return false;
1743
+ }
1744
+ return true;
1681
1745
  };
1682
1746
  pp$8.isAwaitUsing = function(isFor) {
1683
1747
  return this.isUsingKeyword(true, isFor);
@@ -1752,8 +1816,8 @@ pp$8.parseStatement = function(context, topLevel, exports) {
1752
1816
  }
1753
1817
  var usingKind = this.isAwaitUsing(false) ? "await using" : this.isUsing(false) ? "using" : null;
1754
1818
  if (usingKind) {
1755
- if (topLevel && this.options.sourceType === "script") {
1756
- this.raise(this.start, "Using declaration cannot appear in the top level when source type is `script`");
1819
+ if (!this.allowUsing) {
1820
+ this.raise(this.start, "Using declaration cannot appear in the top level when source type is `script` or in the bare case statement");
1757
1821
  }
1758
1822
  if (usingKind === "await using") {
1759
1823
  if (!this.canAwait) {
@@ -1847,6 +1911,9 @@ pp$8.parseForStatement = function(node) {
1847
1911
  var init$2 = this.startNode();
1848
1912
  this.next();
1849
1913
  if (usingKind === "await using") {
1914
+ if (!this.canAwait) {
1915
+ this.raise(this.start, "Await using cannot appear outside of async function");
1916
+ }
1850
1917
  this.next();
1851
1918
  }
1852
1919
  this.parseVar(init$2, true, usingKind);
@@ -1914,7 +1981,7 @@ pp$8.parseIfStatement = function(node) {
1914
1981
  return this.finishNode(node, "IfStatement");
1915
1982
  };
1916
1983
  pp$8.parseReturnStatement = function(node) {
1917
- if (!this.inFunction && !this.options.allowReturnOutsideFunction) {
1984
+ if (!this.allowReturn) {
1918
1985
  this.raise(this.start, "'return' outside of function");
1919
1986
  }
1920
1987
  this.next();
@@ -1932,7 +1999,7 @@ pp$8.parseSwitchStatement = function(node) {
1932
1999
  node.cases = [];
1933
2000
  this.expect(types$1.braceL);
1934
2001
  this.labels.push(switchLabel);
1935
- this.enterScope(0);
2002
+ this.enterScope(SCOPE_SWITCH);
1936
2003
  var cur;
1937
2004
  for (var sawDefault = false; this.type !== types$1.braceR;) {
1938
2005
  if (this.type === types$1._case || this.type === types$1._default) {
@@ -4256,7 +4323,7 @@ pp$2.copyNode = function(node) {
4256
4323
  }
4257
4324
  return newNode;
4258
4325
  };
4259
- var scriptValuesAddedInUnicode = "Gara Garay Gukh Gurung_Khema Hrkt Katakana_Or_Hiragana Kawi Kirat_Rai Krai Nag_Mundari Nagm Ol_Onal Onao Sunu Sunuwar Todhri Todr Tulu_Tigalari Tutg Unknown Zzzz";
4326
+ var scriptValuesAddedInUnicode = "Berf Beria_Erfe Gara Garay Gukh Gurung_Khema Hrkt Katakana_Or_Hiragana Kawi Kirat_Rai Krai Nag_Mundari Nagm Ol_Onal Onao Sidetic Sidt Sunu Sunuwar Tai_Yo Tayo Todhri Todr Tolong_Siki Tols Tulu_Tigalari Tutg Unknown Zzzz";
4260
4327
  var ecma9BinaryProperties = "ASCII ASCII_Hex_Digit AHex Alphabetic Alpha Any Assigned Bidi_Control Bidi_C Bidi_Mirrored Bidi_M Case_Ignorable CI Cased Changes_When_Casefolded CWCF Changes_When_Casemapped CWCM Changes_When_Lowercased CWL Changes_When_NFKC_Casefolded CWKCF Changes_When_Titlecased CWT Changes_When_Uppercased CWU Dash Default_Ignorable_Code_Point DI Deprecated Dep Diacritic Dia Emoji Emoji_Component Emoji_Modifier Emoji_Modifier_Base Emoji_Presentation Extender Ext Grapheme_Base Gr_Base Grapheme_Extend Gr_Ext Hex_Digit Hex IDS_Binary_Operator IDSB IDS_Trinary_Operator IDST ID_Continue IDC ID_Start IDS Ideographic Ideo Join_Control Join_C Logical_Order_Exception LOE Lowercase Lower Math Noncharacter_Code_Point NChar Pattern_Syntax Pat_Syn Pattern_White_Space Pat_WS Quotation_Mark QMark Radical Regional_Indicator RI Sentence_Terminal STerm Soft_Dotted SD Terminal_Punctuation Term Unified_Ideograph UIdeo Uppercase Upper Variation_Selector VS White_Space space XID_Continue XIDC XID_Start XIDS";
4261
4328
  var ecma10BinaryProperties = ecma9BinaryProperties + " Extended_Pictographic";
4262
4329
  var ecma11BinaryProperties = ecma10BinaryProperties;
@@ -5483,14 +5550,17 @@ pp.readToken = function(code) {
5483
5550
  }
5484
5551
  return this.getTokenFromCode(code);
5485
5552
  };
5486
- pp.fullCharCodeAtPos = function() {
5487
- var code = this.input.charCodeAt(this.pos);
5553
+ pp.fullCharCodeAt = function(pos) {
5554
+ var code = this.input.charCodeAt(pos);
5488
5555
  if (code <= 55295 || code >= 56320) {
5489
5556
  return code;
5490
5557
  }
5491
- var next = this.input.charCodeAt(this.pos + 1);
5558
+ var next = this.input.charCodeAt(pos + 1);
5492
5559
  return next <= 56319 || next >= 57344 ? code : (code << 10) + next - 56613888;
5493
5560
  };
5561
+ pp.fullCharCodeAtPos = function() {
5562
+ return this.fullCharCodeAt(this.pos);
5563
+ };
5494
5564
  pp.skipBlockComment = function() {
5495
5565
  var startLoc = this.options.onComment && this.curPosition();
5496
5566
  var start = this.pos, end = this.input.indexOf("*/", this.pos += 2);
@@ -6190,7 +6260,7 @@ pp.readWord = function() {
6190
6260
  }
6191
6261
  return this.finishToken(type, word);
6192
6262
  };
6193
- var version = "8.15.0";
6263
+ var version = "8.16.0";
6194
6264
  Parser.acorn = {
6195
6265
  Parser,
6196
6266
  version,
@@ -12863,21 +12933,6 @@ async function importPluginReactRefresh() {
12863
12933
  const pluginReactRefresh = await interopDefault(import("eslint-plugin-react-refresh"));
12864
12934
  return { pluginReactRefresh };
12865
12935
  }
12866
- async function importParserJsonc() {
12867
- const parserJsonc = await interopDefault(import("jsonc-eslint-parser"));
12868
- return { parserJsonc };
12869
- }
12870
- async function importPluginJsonc() {
12871
- const pluginJsonc = await interopDefault(import("eslint-plugin-jsonc"));
12872
- return { pluginJsonc };
12873
- }
12874
- async function importJsoncLibs() {
12875
- const [{ parserJsonc }, { pluginJsonc }] = await Promise.all([importParserJsonc(), importPluginJsonc()]);
12876
- return {
12877
- parserJsonc,
12878
- pluginJsonc
12879
- };
12880
- }
12881
12936
  async function importPluginMarkdown() {
12882
12937
  const pluginMarkdown = await interopDefault(import("@eslint/markdown"));
12883
12938
  return { pluginMarkdown };
@@ -17332,6 +17387,21 @@ const jsdoc = async () => {
17332
17387
 
17333
17388
  //#endregion
17334
17389
  //#region src/configs/jsonc.ts
17390
+ async function importParserJsonc() {
17391
+ const parserJsonc = await interopDefault(import("jsonc-eslint-parser"));
17392
+ return { parserJsonc };
17393
+ }
17394
+ async function importPluginJsonc() {
17395
+ const pluginJsonc = await interopDefault(import("eslint-plugin-jsonc"));
17396
+ return { pluginJsonc };
17397
+ }
17398
+ async function importJsoncLibs() {
17399
+ const [{ parserJsonc }, { pluginJsonc }] = await Promise.all([importParserJsonc(), importPluginJsonc()]);
17400
+ return {
17401
+ parserJsonc,
17402
+ pluginJsonc
17403
+ };
17404
+ }
17335
17405
  const jsonc = async (options) => {
17336
17406
  const { overrides = {}, stylistic = true } = options ?? {};
17337
17407
  const { indent = 2 } = typeof stylistic === "boolean" ? {} : stylistic;
@@ -19242,4 +19312,4 @@ const presetAll = makePresetFn([
19242
19312
  ]);
19243
19313
 
19244
19314
  //#endregion
19245
- export { SLOW_RULES, VERSION, changeRuleEntrySeverity, combine, combineAsync, jsse as default, jsse, defineConfig, error2warn, globs_exports as globs, importJsoncLibs, importParserJsonc, importPluginJsonc, importPluginMarkdown, importPluginReact, importPluginReactRefresh, importPluginStylistic, importPluginTsdoc, interopDefault, isCI, isInEditor, jsseReact, parserPlain, parserTs, pluginAntfu, pluginDeMorgan, pluginEslintComments, pluginImportLite, pluginN, pluginPerfectionist, pluginPnpm, pluginTs, pluginUnicorn, pluginUnusedImports, renameRules, turnOffRules, uniqueStrings, warn2error };
19315
+ export { SLOW_RULES, VERSION, changeRuleEntrySeverity, combine, combineAsync, jsse as default, jsse, defineConfig, error2warn, globs_exports as globs, importPluginMarkdown, importPluginReact, importPluginReactRefresh, importPluginStylistic, importPluginTsdoc, interopDefault, isCI, isInEditor, jsseReact, parserPlain, parserTs, pluginAntfu, pluginDeMorgan, pluginEslintComments, pluginImportLite, pluginN, pluginPerfectionist, pluginPnpm, pluginTs, pluginUnicorn, pluginUnusedImports, renameRules, turnOffRules, uniqueStrings, warn2error };
@@ -36,7 +36,7 @@ const SLOW_RULES = [
36
36
 
37
37
  //#endregion
38
38
  //#region src/generated/version.ts
39
- const VERSION = "0.5.0";
39
+ const VERSION = "0.5.2";
40
40
 
41
41
  //#endregion
42
42
  export { DEBUG as n, SLOW_RULES as r, VERSION as t };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@jsse/eslint-config",
3
3
  "type": "module",
4
- "version": "0.5.0",
4
+ "version": "0.5.2",
5
5
  "description": "@jsse/eslint-config ~ WYSIWYG",
6
6
  "author": "jessekrubin <jessekrubin@gmail.com> (https://github.com/jessekrubin/)",
7
7
  "license": "MIT",
@@ -64,19 +64,19 @@
64
64
  "@eslint/compat": "^2.0.2",
65
65
  "@eslint/js": "^9.39.2",
66
66
  "@eslint/markdown": "^7.5.1",
67
- "@stylistic/eslint-plugin": "5.7.1",
68
- "@typescript-eslint/eslint-plugin": "^8.54.0",
69
- "@typescript-eslint/parser": "^8.54.0",
70
- "@vitest/eslint-plugin": "^1.6.6",
67
+ "@stylistic/eslint-plugin": "5.9.0",
68
+ "@typescript-eslint/eslint-plugin": "^8.55.0",
69
+ "@typescript-eslint/parser": "^8.55.0",
70
+ "@vitest/eslint-plugin": "^1.6.7",
71
71
  "debug": "^4.4.3",
72
72
  "eslint-config-flat-gitignore": "^2.1.0",
73
73
  "eslint-merge-processors": "^2.0.0",
74
- "eslint-plugin-antfu": "^3.1.3",
74
+ "eslint-plugin-antfu": "^3.2.0",
75
75
  "eslint-plugin-command": "^3.4.0",
76
76
  "eslint-plugin-de-morgan": "^2.0.0",
77
77
  "eslint-plugin-import-lite": "^0.5.0",
78
- "eslint-plugin-jsdoc": "^62.5.2",
79
- "eslint-plugin-jsonc": "^2.21.0",
78
+ "eslint-plugin-jsdoc": "^62.5.4",
79
+ "eslint-plugin-jsonc": "^3.1.1",
80
80
  "eslint-plugin-n": "^17.23.2",
81
81
  "eslint-plugin-no-only-tests": "^3.3.0",
82
82
  "eslint-plugin-perfectionist": "^5.5.0",
@@ -84,14 +84,14 @@
84
84
  "eslint-plugin-react": "^7.37.5",
85
85
  "eslint-plugin-react-hooks": "^7.0.1",
86
86
  "eslint-plugin-react-refresh": "^0.5.0",
87
- "eslint-plugin-toml": "^1.0.3",
87
+ "eslint-plugin-toml": "^1.0.4",
88
88
  "eslint-plugin-tsdoc": "^0.5.0",
89
- "eslint-plugin-unicorn": "^62.0.0",
90
- "eslint-plugin-unused-imports": "^4.3.0",
91
- "eslint-plugin-yml": "^3.0.0",
92
- "jsonc-eslint-parser": "^2.4.2",
89
+ "eslint-plugin-unicorn": "^63.0.0",
90
+ "eslint-plugin-unused-imports": "^4.4.1",
91
+ "eslint-plugin-yml": "^3.1.2",
92
+ "jsonc-eslint-parser": "^3.1.0",
93
93
  "toml-eslint-parser": "^1.0.3",
94
- "typescript-eslint": "^8.54.0",
94
+ "typescript-eslint": "^8.55.0",
95
95
  "yaml-eslint-parser": "^2.0.0"
96
96
  },
97
97
  "devDependencies": {
@@ -100,10 +100,10 @@
100
100
  "@jsse/tsconfig": "^0.4.0",
101
101
  "@types/debug": "^4.1.12",
102
102
  "@types/fs-extra": "^11.0.4",
103
- "@types/node": "^25.2.1",
103
+ "@types/node": "^25.2.3",
104
104
  "cac": "^6.7.14",
105
105
  "eslint": "^9.39.2",
106
- "eslint-flat-config-utils": "^3.0.0",
106
+ "eslint-flat-config-utils": "^3.0.1",
107
107
  "eslint-typegen": "^2.3.0",
108
108
  "execa": "~9.6.1",
109
109
  "fast-equals": "^6.0.0",
@@ -111,7 +111,7 @@
111
111
  "fs-extra": "^11.3.3",
112
112
  "globals": "^17.3.0",
113
113
  "local-pkg": "^1.1.2",
114
- "oxlint": "^1.43.0",
114
+ "oxlint": "^1.46.0",
115
115
  "picocolors": "^1.1.1",
116
116
  "prettier": "^3.8.1",
117
117
  "react": "~19.2.4",