@kitajs/ts-html-plugin 1.0.1 → 1.0.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/README.md CHANGED
@@ -34,6 +34,7 @@
34
34
  - [Installing](#installing)
35
35
  - [Getting Started](#getting-started)
36
36
  - [JSX](#jsx)
37
+ - [Vscode](#vscode)
37
38
 
38
39
  <br />
39
40
 
@@ -70,4 +71,17 @@ manager, and put this inside your `tsconfig.json`.
70
71
  For JSX support, please go to [kitajs/html](https://github.com/kitajs/html) for more
71
72
  information.
72
73
 
74
+ ## Vscode
75
+
76
+ If you are using vscode and this plugin is not working properly, make sure to use the
77
+ current project's typescript version.
78
+
79
+ ```jsonc
80
+ // .vscode/settings.json
81
+
82
+ {
83
+ "typescript.tsdk": "node_modules/typescript/lib"
84
+ }
85
+ ```
86
+
73
87
  <br />
package/SECURITY.md CHANGED
@@ -1,9 +1,9 @@
1
1
  ## Security
2
2
 
3
3
  Due to the nature of this project, security is a top priority. If you believe you have
4
- found security issues like XSS attacks or similar, please report them to me ([`security@arthur.place`](mailto:security@arthur.place)) in a
5
- responsible manner. You will receive a response from
6
- me as soon as possible.
4
+ found security issues like XSS attacks or similar, please report them to me
5
+ ([`security@arthur.place`](mailto:security@arthur.place)) in a responsible manner. You
6
+ will receive a response from me as soon as possible.
7
7
 
8
8
  If the issue is confirmed, I will release a patch as soon as possible depending on
9
- complexity but historically within a few days.
9
+ complexity but historically within a few days.
package/dist/errors.d.ts CHANGED
@@ -10,4 +10,8 @@ export declare const UnusedSafe: {
10
10
  code: number;
11
11
  message: string;
12
12
  };
13
+ export declare const ComponentXss: {
14
+ code: number;
15
+ message: string;
16
+ };
13
17
  //# sourceMappingURL=errors.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../src/errors.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,GAAG;;;CAIf,CAAC;AAEF,eAAO,MAAM,YAAY;;;CAIxB,CAAC;AAEF,eAAO,MAAM,UAAU;;;CAItB,CAAC"}
1
+ {"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../src/errors.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,GAAG;;;CAIf,CAAC;AAEF,eAAO,MAAM,YAAY;;;CAIxB,CAAC;AAEF,eAAO,MAAM,UAAU;;;CAItB,CAAC;AAEF,eAAO,MAAM,YAAY;;;CAIxB,CAAC"}
package/dist/errors.js CHANGED
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.UnusedSafe = exports.DoubleEscape = exports.Xss = void 0;
3
+ exports.ComponentXss = exports.UnusedSafe = exports.DoubleEscape = exports.Xss = void 0;
4
4
  exports.Xss = {
5
5
  code: 27022005,
6
6
  message: 'Usage of JSX expression without safe attribute. This could lead to XSS vulnerabilities. Please use the safe attribute on the JSX element or prepend your variable with `safe`.'
@@ -13,4 +13,8 @@ exports.UnusedSafe = {
13
13
  code: 17091977,
14
14
  message: 'You are using the safe attribute on expressions that does not contain any XSS vulnerabilities. Please remove the safe attribute or prepend your variable with `unsafe`.'
15
15
  };
16
+ exports.ComponentXss = {
17
+ code: 27061977,
18
+ message: 'You are using a xss-prone element as a children of a component. Please wrap it into a Html.escapeHtml() call or prepend it as a variable starting with `safe`.'
19
+ };
16
20
  //# sourceMappingURL=errors.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"errors.js","sourceRoot":"","sources":["../src/errors.ts"],"names":[],"mappings":";;;AAAa,QAAA,GAAG,GAAG;IACjB,IAAI,EAAE,QAAQ;IACd,OAAO,EACL,gLAAgL;CACnL,CAAC;AAEW,QAAA,YAAY,GAAG;IAC1B,IAAI,EAAE,QAAQ;IACd,OAAO,EACL,yOAAyO;CAC5O,CAAC;AAEW,QAAA,UAAU,GAAG;IACxB,IAAI,EAAE,QAAQ;IACd,OAAO,EACL,yKAAyK;CAC5K,CAAC"}
1
+ {"version":3,"file":"errors.js","sourceRoot":"","sources":["../src/errors.ts"],"names":[],"mappings":";;;AAAa,QAAA,GAAG,GAAG;IACjB,IAAI,EAAE,QAAQ;IACd,OAAO,EACL,gLAAgL;CACnL,CAAC;AAEW,QAAA,YAAY,GAAG;IAC1B,IAAI,EAAE,QAAQ;IACd,OAAO,EACL,yOAAyO;CAC5O,CAAC;AAEW,QAAA,UAAU,GAAG;IACxB,IAAI,EAAE,QAAQ;IACd,OAAO,EACL,yKAAyK;CAC5K,CAAC;AAEW,QAAA,YAAY,GAAG;IAC1B,IAAI,EAAE,QAAQ;IACd,OAAO,EACL,gKAAgK;CACnK,CAAC"}
package/dist/index.d.ts CHANGED
@@ -1,8 +1,8 @@
1
- import tss from 'typescript/lib/tsserverlibrary';
2
- declare const _default: ({ typescript: ts }: {
3
- typescript: typeof tss;
1
+ import type { default as TS, server } from 'typescript/lib/tsserverlibrary';
2
+ declare const _default: (modules: {
3
+ typescript: typeof TS;
4
4
  }) => {
5
- create(info: tss.server.PluginCreateInfo): tss.LanguageService;
5
+ create(info: server.PluginCreateInfo): TS.LanguageService;
6
6
  };
7
7
  export = _default;
8
8
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,GAAG,MAAM,gCAAgC,CAAC;6CAGI;IAAE,UAAU,EAAE,UAAU,CAAA;CAAE;iBAE9D,IAAI,MAAM,CAAC,gBAAgB;;AAF5C,kBAgCE"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,IAAI,EAAE,EAAE,MAAM,EAAE,MAAM,gCAAgC,CAAC;kCAGlC;IAAE,UAAU,EAAE,SAAS,CAAA;CAAE;iBAIlD,OAAO,gBAAgB;;AAJxC,kBAuCE"}
package/dist/index.js CHANGED
@@ -1,6 +1,7 @@
1
1
  "use strict";
2
2
  const util_1 = require("./util");
3
- module.exports = function initHtmlPlugin({ typescript: ts }) {
3
+ module.exports = function initHtmlPlugin(modules) {
4
+ const ts = modules.typescript;
4
5
  return {
5
6
  create(info) {
6
7
  const proxy = (0, util_1.proxyObject)(info.languageService);
@@ -11,13 +12,16 @@ module.exports = function initHtmlPlugin({ typescript: ts }) {
11
12
  return diagnostics;
12
13
  }
13
14
  const program = info.languageService.getProgram();
15
+ if (!program) {
16
+ return diagnostics;
17
+ }
14
18
  const source = program?.getSourceFile(filename);
15
- if (!program || !source) {
19
+ if (!source) {
16
20
  return diagnostics;
17
21
  }
18
22
  const typeChecker = program.getTypeChecker();
19
23
  ts.forEachChild(source, function loopSourceNodes(node) {
20
- (0, util_1.recursiveDiagnoseJsxElements)(node, typeChecker, diagnostics);
24
+ (0, util_1.recursiveDiagnoseJsxElements)(ts, node, typeChecker, diagnostics);
21
25
  });
22
26
  return diagnostics;
23
27
  };
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AACA,iCAAmE;AAEnE,iBAAS,SAAS,cAAc,CAAC,EAAE,UAAU,EAAE,EAAE,EAA8B;IAC7E,OAAO;QACL,MAAM,CAAC,IAAiC;YACtC,MAAM,KAAK,GAAG,IAAA,kBAAW,EAAC,IAAI,CAAC,eAAe,CAAC,CAAC;YAEhD,KAAK,CAAC,sBAAsB,GAAG,SAAS,yBAAyB,CAAC,QAAQ;gBACxE,MAAM,WAAW,GAAG,IAAI,CAAC,eAAe,CAAC,sBAAsB,CAAC,QAAQ,CAAC,CAAC;gBAE1E,uCAAuC;gBACvC,IAAI,CAAC,QAAQ,CAAC,KAAK,CAAC,UAAU,CAAC,EAAE;oBAC/B,OAAO,WAAW,CAAC;iBACpB;gBAED,MAAM,OAAO,GAAG,IAAI,CAAC,eAAe,CAAC,UAAU,EAAE,CAAC;gBAClD,MAAM,MAAM,GAAG,OAAO,EAAE,aAAa,CAAC,QAAQ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W,GAAG,OAAO,CAAC,cAAc,EAAE,CAAC;gBAE7C,EAAE,CAAC,YAAY,CAAC,MAAM,EAAE,SAAS,eAAe,CAAC,IAAI;oBACnD,IAAA,mCAA4B,EAAC,EAAE,EAAE,IAAI,EAAE,WAAW,EAAE,WAAW,CAAC,CAAC;gBACnE,CAAC,CAAC,CAAC;gBAEH,OAAO,WAAW,CAAC;YACrB,CAAC,CAAC;YAEF,OAAO,KAAK,CAAC;QACf,CAAC;KACF,CAAC;AACJ,CAAC,CAAC"}
@@ -1 +1 @@
1
- {"program":{"fileNames":["../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es5.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2015.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2016.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2017.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2018.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2019.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2020.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2021.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2022.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2023.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.esnext.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.dom.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.dom.iterable.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.webworker.importscripts.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.scripthost.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2015.core.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2015.collection.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2015.generator.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2015.iterable.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2015.promise.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2015.proxy.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2015.reflect.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2015.symbol.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2016.array.include.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2017.date.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2017.object.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2017.string.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2017.intl.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2017.typedarrays.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2018.asynciterable.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2018.intl.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2018.promise.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2018.regexp.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2019.array.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2019.object.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2019.string.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2019.symbol.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2019.intl.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2020.bigint.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2020.date.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2020.promise.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2020.sharedmemory.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2020.string.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2020.symbol.wellknown.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2020.intl.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2020.number.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2021.promise.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2021.string.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2021.weakref.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2021.intl.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2022.array.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2022.error.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2022.intl.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2022.object.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2022.sharedmemory.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2022.string.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2022.regexp.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2023.array.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2023.collection.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.esnext.intl.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.esnext.disposable.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.esnext.decorators.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.decorators.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.decorators.legacy.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.esnext.full.d.ts","../node_modules/.pnpm/tslib@2.6.2/node_modules/tslib/tslib.d.ts","../src/errors.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/tsserverlibrary.d.ts","../src/util.ts","../src/index.ts","../node_modules/.pnpm/prettier@3.0.3/node_modules/prettier/doc.d.ts","../node_modules/.pnpm/prettier@3.0.3/node_modules/prettier/index.d.ts"],"fileInfos":[{"version":"2ac9cdcfb8f8875c18d14ec5796a8b029c426f73ad6dc3ffb580c228b58d1c44","affectsGlobalScope":true},"45b7ab580deca34ae9729e97c13cfd999df04416a79116c3bfb483804f85ded4","dc48272d7c333ccf58034c0026162576b7d50ea0e69c3b9292f803fc20720fd5","9a68c0c07ae2fa71b44384a839b7b8d81662a236d4b9ac30916718f7510b1b2d","5e1c4c362065a6b95ff952c0eab010f04dcd2c3494e813b493ecfd4fcb9fc0d8","68d73b4a11549f9c0b7d352d10e91e5dca8faa3322bfb77b661839c42b1ddec7","5efce4fc3c29ea84e8928f97adec086e3dc876365e0982cc8479a07954a3efd4","feecb1be483ed332fad555aff858affd90a48ab19ba7272ee084704eb7167569","5514e54f17d6d74ecefedc73c504eadffdeda79c7ea205cf9febead32d45c4bc","1c0cdb8dc619bc549c3e5020643e7cf7ae7940058e8c7e5aefa5871b6d86f44b","bed7b7ba0eb5a160b69af72814b4dde371968e40b6c5e73d3a9f7bee407d158c",{"version":"0075fa5ceda385bcdf3488e37786b5a33be730e8bc4aa3cf1e78c63891752ce8","affectsGlobalScope":true},{"version":"35299ae4a62086698444a5aaee27fc7aa377c68cbb90b441c9ace246ffd05c97","affectsGlobalScope":true},{"version":"c5c5565225fce2ede835725a92a28ece149f83542aa4866cfb10290bff7b8996","affectsGlobalScope":true},{"version":"7d2dbc2a0250400af0809b0ad5f84686e84c73526de931f84560e483eb16b03c","affectsGlobalScope":true},{"version":"f296963760430fb65b4e5d91f0ed770a91c6e77455bacf8fa23a1501654ede0e","affectsGlobalScope":true},{"version":"09226e53d1cfda217317074a97724da3e71e2c545e18774484b61562afc53cd2","affectsGlobalScope":true},{"version":"4443e68b35f3332f753eacc66a04ac1d2053b8b035a0e0ac1d455392b5e243b3","affectsGlobalScope":true},{"version":"8b41361862022eb72fcc8a7f34680ac842aca802cf4bc1f915e8c620c9ce4331","affectsGlobalScope":true},{"version":"f7bd636ae3a4623c503359ada74510c4005df5b36de7f23e1db8a5c543fd176b","affectsGlobalScope":true},{"version":"ce691fb9e5c64efb9547083e4a34091bcbe5bdb41027e310ebba8f7d96a98671","affectsGlobalScope":true},{"version":"8d697a2a929a5fcb38b7a65594020fcef05ec1630804a33748829c5ff53640d0","affectsGlobalScope":true},{"version":"0c20f4d2358eb679e4ae8a4432bdd96c857a2960fd6800b21ec4008ec59d60ea","affectsGlobalScope":true},{"version":"93495ff27b8746f55d19fcbcdbaccc99fd95f19d057aed1bd2c0cafe1335fbf0","affectsGlobalScope":true},{"version":"82d0d8e269b9eeac02c3bd1c9e884e85d483fcb2cd168bccd6bc54df663da031","affectsGlobalScope":true},{"version":"38f0219c9e23c915ef9790ab1d680440d95419ad264816fa15009a8851e79119","affectsGlobalScope":true},{"version":"b8deab98702588840be73d67f02412a2d45a417a3c097b2e96f7f3a42ac483d1","affectsGlobalScope":true},{"version":"4738f2420687fd85629c9efb470793bb753709c2379e5f85bc1815d875ceadcd","affectsGlobalScope":true},{"version":"2f11ff796926e0832f9ae148008138ad583bd181899ab7dd768a2666700b1893","affectsGlobalScope":true},{"version":"376d554d042fb409cb55b5cbaf0b2b4b7e669619493c5d18d5fa8bd67273f82a","affectsGlobalScope":true},{"version":"9fc46429fbe091ac5ad2608c657201eb68b6f1b8341bd6d670047d32ed0a88fa","affectsGlobalScope":true},{"version":"61c37c1de663cf4171e1192466e52c7a382afa58da01b1dc75058f032ddf0839","affectsGlobalScope":true},{"version":"c4138a3dd7cd6cf1f363ca0f905554e8d81b45844feea17786cdf1626cb8ea06","affectsGlobalScope":true},{"version":"6ff3e2452b055d8f0ec026511c6582b55d935675af67cdb67dd1dc671e8065df","affectsGlobalScope":true},{"version":"03de17b810f426a2f47396b0b99b53a82c1b60e9cba7a7edda47f9bb077882f4","affectsGlobalScope":true},{"version":"8184c6ddf48f0c98429326b428478ecc6143c27f79b79e85740f17e6feb090f1","affectsGlobalScope":true},{"version":"261c4d2cf86ac5a89ad3fb3fafed74cbb6f2f7c1d139b0540933df567d64a6ca","affectsGlobalScope":true},{"version":"6af1425e9973f4924fca986636ac19a0cf9909a7e0d9d3009c349e6244e957b6","affectsGlobalScope":true},{"version":"576711e016cf4f1804676043e6a0a5414252560eb57de9faceee34d79798c850","affectsGlobalScope":true},{"version":"89c1b1281ba7b8a96efc676b11b264de7a8374c5ea1e6617f11880a13fc56dc6","affectsGlobalScope":true},{"version":"15a630d6817718a2ddd7088c4f83e4673fde19fa992d2eae2cf51132a302a5d3","affectsGlobalScope":true},{"version":"b7e9f95a7387e3f66be0ed6db43600c49cec33a3900437ce2fd350d9b7cb16f2","affectsGlobalScope":true},{"version":"01e0ee7e1f661acedb08b51f8a9b7d7f959e9cdb6441360f06522cc3aea1bf2e","affectsGlobalScope":true},{"version":"ac17a97f816d53d9dd79b0d235e1c0ed54a8cc6a0677e9a3d61efb480b2a3e4e","affectsGlobalScope":true},{"version":"bf14a426dbbf1022d11bd08d6b8e709a2e9d246f0c6c1032f3b2edb9a902adbe","affectsGlobalScope":true},{"version":"ec0104fee478075cb5171e5f4e3f23add8e02d845ae0165bfa3f1099241fa2aa","affectsGlobalScope":true},{"version":"2b72d528b2e2fe3c57889ca7baef5e13a56c957b946906d03767c642f386bbc3","affectsGlobalScope":true},{"version":"9cc66b0513ad41cb5f5372cca86ef83a0d37d1c1017580b7dace3ea5661836df","affectsGlobalScope":true},{"version":"368af93f74c9c932edd84c58883e736c9e3d53cec1fe24c0b0ff451f529ceab1","affectsGlobalScope":true},{"version":"709efdae0cb5df5f49376cde61daacc95cdd44ae4671da13a540da5088bf3f30","affectsGlobalScope":true},{"version":"995c005ab91a498455ea8dfb63aa9f83fa2ea793c3d8aa344be4a1678d06d399","affectsGlobalScope":true},{"version":"bc496ef4377553e461efcf7cc5a5a57cf59f9962aea06b5e722d54a36bf66ea1","affectsGlobalScope":true},{"version":"038a2f66a34ee7a9c2fbc3584c8ab43dff2995f8c68e3f566f4c300d2175e31e","affectsGlobalScope":true},{"version":"4fa6ed14e98aa80b91f61b9805c653ee82af3502dc21c9da5268d3857772ca05","affectsGlobalScope":true},{"version":"f5c92f2c27b06c1a41b88f6db8299205aee52c2a2943f7ed29bd585977f254e8","affectsGlobalScope":true},{"version":"930b0e15811f84e203d3c23508674d5ded88266df4b10abee7b31b2ac77632d2","affectsGlobalScope":true},{"version":"8444af78980e3b20b49324f4a16ba35024fef3ee069a0eb67616ea6ca821c47a","affectsGlobalScope":true},{"version":"b9ea5778ff8b50d7c04c9890170db34c26a5358cccba36844fe319f50a43a61a","affectsGlobalScope":true},{"version":"3287d9d085fbd618c3971944b65b4be57859f5415f495b33a6adc994edd2f004","affectsGlobalScope":true},{"version":"50d53ccd31f6667aff66e3d62adf948879a3a16f05d89882d1188084ee415bbc","affectsGlobalScope":true},{"version":"65be38e881453e16f128a12a8d36f8b012aa279381bf3d4dc4332a4905ceec83","affectsGlobalScope":true},{"version":"436aaf437562f276ec2ddbee2f2cdedac7664c1e4c1d2c36839ddd582eeb3d0a","affectsGlobalScope":true},{"version":"307c8b7ebbd7f23a92b73a4c6c0a697beca05b06b036c23a34553e5fe65e4fdc","affectsGlobalScope":true},{"version":"e1913f656c156a9e4245aa111fbb436d357d9e1fe0379b9a802da7fe3f03d736","affectsGlobalScope":true},{"version":"d4b1d2c51d058fc21ec2629fff7a76249dec2e36e12960ea056e3ef89174080f","affectsGlobalScope":true},{"version":"f35a831e4f0fe3b3697f4a0fe0e3caa7624c92b78afbecaf142c0f93abfaf379","affectsGlobalScope":true},{"version":"782dec38049b92d4e85c1585fbea5474a219c6984a35b004963b00beb1aab538","affectsGlobalScope":true},"7823c8aa42d88e6cb454fe7dc56996c6fd174b28a9f050e9bdea1c25b7d114ea","7a1971efcba559ea9002ada4c4e3c925004fb67a755300d53b5edf9399354900",{"version":"2a14da481c0c2dbca3210f74923b523ac791c547de69af0ccaf4fe2aeda586bc","signature":"46292ed3f014f70c5de62662cb24f76e2a5122089698ba9818195e7666bc3f0d"},"f9c2563439fc156b5d08d92ba998db0cd1302e65f8bb29a21eae42f97ff4ee6c",{"version":"12da6f27dbcfd89a18d8b933a9d8cfb812a4fba05863e7f5b914ff736b5ff0c8","signature":"37ae35a1cb84aca9af6d1eb0056eb429a05330218aa026445b63cb9e1d7565a4"},{"version":"cfc364ad6e0854649e0ca3565c89c1da1ea1f6f3f08a97004fb23e87b83f93fd","signature":"8e829b28dbf13a36cefbd3d0e0c4899741c40cb133c60b82ec0a7709a5f3a0ae"},"2f848b4e660b568651a6350565afc8ac5b0644853a2a863862807602cf244a05","87c316128d18c34881619a529fe0446125405fa073f1a9e533a8f66f66b6b340"],"root":[70,72,73],"options":{"alwaysStrict":true,"declaration":true,"declarationMap":true,"esModuleInterop":true,"exactOptionalPropertyTypes":true,"importHelpers":true,"jsx":2,"module":1,"noFallthroughCasesInSwitch":true,"noImplicitAny":true,"noImplicitOverride":true,"noImplicitReturns":true,"noImplicitThis":true,"noUncheckedIndexedAccess":true,"noUnusedLocals":true,"noUnusedParameters":true,"outDir":"./","skipDefaultLibCheck":true,"sourceMap":true,"strict":true,"strictBindCallApply":true,"strictFunctionTypes":true,"strictNullChecks":true,"strictPropertyInitialization":true,"target":99,"useUnknownInCatchVariables":true},"fileIdsList":[[74],[69],[69,71,72],[69,70,71],[71]],"referencedMap":[[75,1],[70,2],[73,3],[72,4]],"exportedModulesMap":[[75,1],[73,5],[72,5]],"semanticDiagnosticsPerFile":[74,75,69,66,67,12,13,17,16,2,18,19,20,21,22,23,24,25,3,4,26,30,27,28,29,31,32,33,5,34,35,36,37,6,41,38,39,40,42,7,43,48,49,44,45,46,47,8,53,50,51,52,54,9,55,56,57,60,58,59,61,62,10,1,11,65,64,68,63,15,14,71,70,73,72]},"version":"5.2.2"}
1
+ {"program":{"fileNames":["../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es5.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2015.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2016.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2017.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2018.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2019.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2020.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2021.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2022.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2023.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.esnext.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.dom.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.dom.iterable.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.webworker.importscripts.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.scripthost.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2015.core.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2015.collection.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2015.generator.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2015.iterable.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2015.promise.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2015.proxy.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2015.reflect.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2015.symbol.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2016.array.include.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2017.date.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2017.object.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2017.string.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2017.intl.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2017.typedarrays.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2018.asynciterable.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2018.intl.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2018.promise.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2018.regexp.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2019.array.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2019.object.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2019.string.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2019.symbol.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2019.intl.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2020.bigint.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2020.date.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2020.promise.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2020.sharedmemory.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2020.string.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2020.symbol.wellknown.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2020.intl.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2020.number.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2021.promise.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2021.string.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2021.weakref.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2021.intl.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2022.array.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2022.error.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2022.intl.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2022.object.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2022.sharedmemory.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2022.string.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2022.regexp.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2023.array.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.es2023.collection.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.esnext.intl.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.esnext.disposable.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.esnext.decorators.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.decorators.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.decorators.legacy.d.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/lib.esnext.full.d.ts","../node_modules/.pnpm/tslib@2.6.2/node_modules/tslib/tslib.d.ts","../src/errors.ts","../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/lib/tsserverlibrary.d.ts","../src/util.ts","../src/index.ts","../node_modules/.pnpm/prettier@3.0.3/node_modules/prettier/doc.d.ts","../node_modules/.pnpm/prettier@3.0.3/node_modules/prettier/index.d.ts"],"fileInfos":[{"version":"2ac9cdcfb8f8875c18d14ec5796a8b029c426f73ad6dc3ffb580c228b58d1c44","affectsGlobalScope":true},"45b7ab580deca34ae9729e97c13cfd999df04416a79116c3bfb483804f85ded4","dc48272d7c333ccf58034c0026162576b7d50ea0e69c3b9292f803fc20720fd5","9a68c0c07ae2fa71b44384a839b7b8d81662a236d4b9ac30916718f7510b1b2d","5e1c4c362065a6b95ff952c0eab010f04dcd2c3494e813b493ecfd4fcb9fc0d8","68d73b4a11549f9c0b7d352d10e91e5dca8faa3322bfb77b661839c42b1ddec7","5efce4fc3c29ea84e8928f97adec086e3dc876365e0982cc8479a07954a3efd4","feecb1be483ed332fad555aff858affd90a48ab19ba7272ee084704eb7167569","5514e54f17d6d74ecefedc73c504eadffdeda79c7ea205cf9febead32d45c4bc","1c0cdb8dc619bc549c3e5020643e7cf7ae7940058e8c7e5aefa5871b6d86f44b","bed7b7ba0eb5a160b69af72814b4dde371968e40b6c5e73d3a9f7bee407d158c",{"version":"0075fa5ceda385bcdf3488e37786b5a33be730e8bc4aa3cf1e78c63891752ce8","affectsGlobalScope":true},{"version":"35299ae4a62086698444a5aaee27fc7aa377c68cbb90b441c9ace246ffd05c97","affectsGlobalScope":true},{"version":"c5c5565225fce2ede835725a92a28ece149f83542aa4866cfb10290bff7b8996","affectsGlobalScope":true},{"version":"7d2dbc2a0250400af0809b0ad5f84686e84c73526de931f84560e483eb16b03c","affectsGlobalScope":true},{"version":"f296963760430fb65b4e5d91f0ed770a91c6e77455bacf8fa23a1501654ede0e","affectsGlobalScope":true},{"version":"09226e53d1cfda217317074a97724da3e71e2c545e18774484b61562afc53cd2","affectsGlobalScope":true},{"version":"4443e68b35f3332f753eacc66a04ac1d2053b8b035a0e0ac1d455392b5e243b3","affectsGlobalScope":true},{"version":"8b41361862022eb72fcc8a7f34680ac842aca802cf4bc1f915e8c620c9ce4331","affectsGlobalScope":true},{"version":"f7bd636ae3a4623c503359ada74510c4005df5b36de7f23e1db8a5c543fd176b","affectsGlobalScope":true},{"version":"ce691fb9e5c64efb9547083e4a34091bcbe5bdb41027e310ebba8f7d96a98671","affectsGlobalScope":true},{"version":"8d697a2a929a5fcb38b7a65594020fcef05ec1630804a33748829c5ff53640d0","affectsGlobalScope":true},{"version":"0c20f4d2358eb679e4ae8a4432bdd96c857a2960fd6800b21ec4008ec59d60ea","affectsGlobalScope":true},{"version":"93495ff27b8746f55d19fcbcdbaccc99fd95f19d057aed1bd2c0cafe1335fbf0","affectsGlobalScope":true},{"version":"82d0d8e269b9eeac02c3bd1c9e884e85d483fcb2cd168bccd6bc54df663da031","affectsGlobalScope":true},{"version":"38f0219c9e23c915ef9790ab1d680440d95419ad264816fa15009a8851e79119","affectsGlobalScope":true},{"version":"b8deab98702588840be73d67f02412a2d45a417a3c097b2e96f7f3a42ac483d1","affectsGlobalScope":true},{"version":"4738f2420687fd85629c9efb470793bb753709c2379e5f85bc1815d875ceadcd","affectsGlobalScope":true},{"version":"2f11ff796926e0832f9ae148008138ad583bd181899ab7dd768a2666700b1893","affectsGlobalScope":true},{"version":"376d554d042fb409cb55b5cbaf0b2b4b7e669619493c5d18d5fa8bd67273f82a","affectsGlobalScope":true},{"version":"9fc46429fbe091ac5ad2608c657201eb68b6f1b8341bd6d670047d32ed0a88fa","affectsGlobalScope":true},{"version":"61c37c1de663cf4171e1192466e52c7a382afa58da01b1dc75058f032ddf0839","affectsGlobalScope":true},{"version":"c4138a3dd7cd6cf1f363ca0f905554e8d81b45844feea17786cdf1626cb8ea06","affectsGlobalScope":true},{"version":"6ff3e2452b055d8f0ec026511c6582b55d935675af67cdb67dd1dc671e8065df","affectsGlobalScope":true},{"version":"03de17b810f426a2f47396b0b99b53a82c1b60e9cba7a7edda47f9bb077882f4","affectsGlobalScope":true},{"version":"8184c6ddf48f0c98429326b428478ecc6143c27f79b79e85740f17e6feb090f1","affectsGlobalScope":true},{"version":"261c4d2cf86ac5a89ad3fb3fafed74cbb6f2f7c1d139b0540933df567d64a6ca","affectsGlobalScope":true},{"version":"6af1425e9973f4924fca986636ac19a0cf9909a7e0d9d3009c349e6244e957b6","affectsGlobalScope":true},{"version":"576711e016cf4f1804676043e6a0a5414252560eb57de9faceee34d79798c850","affectsGlobalScope":true},{"version":"89c1b1281ba7b8a96efc676b11b264de7a8374c5ea1e6617f11880a13fc56dc6","affectsGlobalScope":true},{"version":"15a630d6817718a2ddd7088c4f83e4673fde19fa992d2eae2cf51132a302a5d3","affectsGlobalScope":true},{"version":"b7e9f95a7387e3f66be0ed6db43600c49cec33a3900437ce2fd350d9b7cb16f2","affectsGlobalScope":true},{"version":"01e0ee7e1f661acedb08b51f8a9b7d7f959e9cdb6441360f06522cc3aea1bf2e","affectsGlobalScope":true},{"version":"ac17a97f816d53d9dd79b0d235e1c0ed54a8cc6a0677e9a3d61efb480b2a3e4e","affectsGlobalScope":true},{"version":"bf14a426dbbf1022d11bd08d6b8e709a2e9d246f0c6c1032f3b2edb9a902adbe","affectsGlobalScope":true},{"version":"ec0104fee478075cb5171e5f4e3f23add8e02d845ae0165bfa3f1099241fa2aa","affectsGlobalScope":true},{"version":"2b72d528b2e2fe3c57889ca7baef5e13a56c957b946906d03767c642f386bbc3","affectsGlobalScope":true},{"version":"9cc66b0513ad41cb5f5372cca86ef83a0d37d1c1017580b7dace3ea5661836df","affectsGlobalScope":true},{"version":"368af93f74c9c932edd84c58883e736c9e3d53cec1fe24c0b0ff451f529ceab1","affectsGlobalScope":true},{"version":"709efdae0cb5df5f49376cde61daacc95cdd44ae4671da13a540da5088bf3f30","affectsGlobalScope":true},{"version":"995c005ab91a498455ea8dfb63aa9f83fa2ea793c3d8aa344be4a1678d06d399","affectsGlobalScope":true},{"version":"bc496ef4377553e461efcf7cc5a5a57cf59f9962aea06b5e722d54a36bf66ea1","affectsGlobalScope":true},{"version":"038a2f66a34ee7a9c2fbc3584c8ab43dff2995f8c68e3f566f4c300d2175e31e","affectsGlobalScope":true},{"version":"4fa6ed14e98aa80b91f61b9805c653ee82af3502dc21c9da5268d3857772ca05","affectsGlobalScope":true},{"version":"f5c92f2c27b06c1a41b88f6db8299205aee52c2a2943f7ed29bd585977f254e8","affectsGlobalScope":true},{"version":"930b0e15811f84e203d3c23508674d5ded88266df4b10abee7b31b2ac77632d2","affectsGlobalScope":true},{"version":"8444af78980e3b20b49324f4a16ba35024fef3ee069a0eb67616ea6ca821c47a","affectsGlobalScope":true},{"version":"b9ea5778ff8b50d7c04c9890170db34c26a5358cccba36844fe319f50a43a61a","affectsGlobalScope":true},{"version":"3287d9d085fbd618c3971944b65b4be57859f5415f495b33a6adc994edd2f004","affectsGlobalScope":true},{"version":"50d53ccd31f6667aff66e3d62adf948879a3a16f05d89882d1188084ee415bbc","affectsGlobalScope":true},{"version":"65be38e881453e16f128a12a8d36f8b012aa279381bf3d4dc4332a4905ceec83","affectsGlobalScope":true},{"version":"436aaf437562f276ec2ddbee2f2cdedac7664c1e4c1d2c36839ddd582eeb3d0a","affectsGlobalScope":true},{"version":"307c8b7ebbd7f23a92b73a4c6c0a697beca05b06b036c23a34553e5fe65e4fdc","affectsGlobalScope":true},{"version":"e1913f656c156a9e4245aa111fbb436d357d9e1fe0379b9a802da7fe3f03d736","affectsGlobalScope":true},{"version":"d4b1d2c51d058fc21ec2629fff7a76249dec2e36e12960ea056e3ef89174080f","affectsGlobalScope":true},{"version":"f35a831e4f0fe3b3697f4a0fe0e3caa7624c92b78afbecaf142c0f93abfaf379","affectsGlobalScope":true},{"version":"782dec38049b92d4e85c1585fbea5474a219c6984a35b004963b00beb1aab538","affectsGlobalScope":true},"7823c8aa42d88e6cb454fe7dc56996c6fd174b28a9f050e9bdea1c25b7d114ea","7a1971efcba559ea9002ada4c4e3c925004fb67a755300d53b5edf9399354900",{"version":"602ab005a565f7ce744b802dc17f9e647ff81f2525abe4bceda23aac39f1d2aa","signature":"3c60a0a2ef2735b1ba5bd211eb778164d371bb23ba0173cdd94fe109da52a6c0"},"f9c2563439fc156b5d08d92ba998db0cd1302e65f8bb29a21eae42f97ff4ee6c",{"version":"6479817b1a16ebad73c1cd4a5c70cce28e30e30b2e3398159589e46c25461d70","signature":"55094ec7a9f5e027d347658f2ec090e2bd6dc1750b104631cae739954054ae3a"},{"version":"785acb56136645f5114f8eab2b36114ab338514e0254b39b06a2bf391e7146ad","signature":"15f327a31a2696c9ceaa67e73ba0d4c55bee1728196299ecc5150b2e6d11b76d"},"2f848b4e660b568651a6350565afc8ac5b0644853a2a863862807602cf244a05","87c316128d18c34881619a529fe0446125405fa073f1a9e533a8f66f66b6b340"],"root":[70,72,73],"options":{"alwaysStrict":true,"declaration":true,"declarationMap":true,"esModuleInterop":true,"exactOptionalPropertyTypes":true,"importHelpers":true,"jsx":2,"module":1,"noFallthroughCasesInSwitch":true,"noImplicitAny":true,"noImplicitOverride":true,"noImplicitReturns":true,"noImplicitThis":true,"noUncheckedIndexedAccess":true,"noUnusedLocals":true,"noUnusedParameters":true,"outDir":"./","skipDefaultLibCheck":true,"sourceMap":true,"strict":true,"strictBindCallApply":true,"strictFunctionTypes":true,"strictNullChecks":true,"strictPropertyInitialization":true,"target":99,"useUnknownInCatchVariables":true},"fileIdsList":[[74],[69],[69,71,72],[69,70,71],[71]],"referencedMap":[[75,1],[70,2],[73,3],[72,4]],"exportedModulesMap":[[75,1],[73,5],[72,5]],"semanticDiagnosticsPerFile":[74,75,69,66,67,12,13,17,16,2,18,19,20,21,22,23,24,25,3,4,26,30,27,28,29,31,32,33,5,34,35,36,37,6,41,38,39,40,42,7,43,48,49,44,45,46,47,8,53,50,51,52,54,9,55,56,57,60,58,59,61,62,10,1,11,65,64,68,63,15,14,71,70,73,72]},"version":"5.2.2"}
package/dist/util.d.ts CHANGED
@@ -1,7 +1,7 @@
1
- import ts from 'typescript/lib/tsserverlibrary';
2
- export declare function recursiveDiagnoseJsxElements(node: ts.Node, typeChecker: ts.TypeChecker, original: ts.Diagnostic[]): void;
3
- export declare function diagnoseJsxElement(node: ts.JsxElement, typeChecker: ts.TypeChecker, diagnostics: ts.Diagnostic[]): void;
4
- export declare function isSafeAttribute(type: ts.Type, expression: ts.Node): boolean;
5
- export declare function getSafeAttribute(element: ts.JsxOpeningElement): ts.JsxAttributeLike | undefined;
1
+ import type { Diagnostic, JsxElement, JsxOpeningElement, Node, default as TS, Type, TypeChecker } from 'typescript/lib/tsserverlibrary';
2
+ export declare function recursiveDiagnoseJsxElements(ts: typeof TS, node: Node, typeChecker: TypeChecker, original: Diagnostic[]): void;
3
+ export declare function diagnoseJsxElement(ts: typeof TS, node: JsxElement, typeChecker: TypeChecker, diagnostics: Diagnostic[]): void;
4
+ export declare function isSafeAttribute(ts: typeof TS, type: Type, expression: Node): boolean;
5
+ export declare function getSafeAttribute(element: JsxOpeningElement): TS.JsxAttributeLike | undefined;
6
6
  export declare function proxyObject<T extends object>(obj: T): T;
7
7
  //# sourceMappingURL=util.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"util.d.ts","sourceRoot":"","sources":["../src/util.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,gCAAgC,CAAC;AAGhD,wBAAgB,4BAA4B,CAC1C,IAAI,EAAE,EAAE,CAAC,IAAI,EACb,WAAW,EAAE,EAAE,CAAC,WAAW,EAC3B,QAAQ,EAAE,EAAE,CAAC,UAAU,EAAE,QAY1B;AAED,wBAAgB,kBAAkB,CAChC,IAAI,EAAE,EAAE,CAAC,UAAU,EACnB,WAAW,EAAE,EAAE,CAAC,WAAW,EAC3B,WAAW,EAAE,EAAE,CAAC,UAAU,EAAE,GAC3B,IAAI,CAuHN;AAED,wBAAgB,eAAe,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,EAAE,UAAU,EAAE,EAAE,CAAC,IAAI,WAkBjE;AAED,wBAAgB,gBAAgB,CAAC,OAAO,EAAE,EAAE,CAAC,iBAAiB,mCAQ7D;AAED,wBAAgB,WAAW,CAAC,CAAC,SAAS,MAAM,EAAE,GAAG,EAAE,CAAC,GAAG,CAAC,CAUvD"}
1
+ {"version":3,"file":"util.d.ts","sourceRoot":"","sources":["../src/util.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,UAAU,EACV,UAAU,EACV,iBAAiB,EACjB,IAAI,EACJ,OAAO,IAAI,EAAE,EACb,IAAI,EACJ,WAAW,EACZ,MAAM,gCAAgC,CAAC;AAMxC,wBAAgB,4BAA4B,CAC1C,EAAE,EAAE,OAAO,EAAE,EACb,IAAI,EAAE,IAAI,EACV,WAAW,EAAE,WAAW,EACxB,QAAQ,EAAE,UAAU,EAAE,QAYvB;AAED,wBAAgB,kBAAkB,CAChC,EAAE,EAAE,OAAO,EAAE,EACb,IAAI,EAAE,UAAU,EAChB,WAAW,EAAE,WAAW,EACxB,WAAW,EAAE,UAAU,EAAE,GACxB,IAAI,CAkIN;AAED,wBAAgB,eAAe,CAAC,EAAE,EAAE,OAAO,EAAE,EAAE,IAAI,EAAE,IAAI,EAAE,UAAU,EAAE,IAAI,WAwB1E;AAED,wBAAgB,gBAAgB,CAAC,OAAO,EAAE,iBAAiB,mCAQ1D;AAED,wBAAgB,WAAW,CAAC,CAAC,SAAS,MAAM,EAAE,GAAG,EAAE,CAAC,GAAG,CAAC,CAUvD"}
package/dist/util.js CHANGED
@@ -2,21 +2,22 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.proxyObject = exports.getSafeAttribute = exports.isSafeAttribute = exports.diagnoseJsxElement = exports.recursiveDiagnoseJsxElements = void 0;
4
4
  const tslib_1 = require("tslib");
5
- const tsserverlibrary_1 = tslib_1.__importDefault(require("typescript/lib/tsserverlibrary"));
6
5
  const Errors = tslib_1.__importStar(require("./errors"));
7
- function recursiveDiagnoseJsxElements(node, typeChecker, original) {
8
- tsserverlibrary_1.default.forEachChild(node, function loopSourceNodes(node) {
6
+ const UPPERCASE = /[A-Z]/;
7
+ const ESCAPE_HTML_REGEX = /^(\w+\.)?escapeHtml/i;
8
+ function recursiveDiagnoseJsxElements(ts, node, typeChecker, original) {
9
+ ts.forEachChild(node, function loopSourceNodes(node) {
9
10
  // Recurse through children first
10
- tsserverlibrary_1.default.forEachChild(node, loopSourceNodes);
11
+ ts.forEachChild(node, loopSourceNodes);
11
12
  // Adds children to the array
12
- if (tsserverlibrary_1.default.isJsxElement(node)) {
13
+ if (ts.isJsxElement(node)) {
13
14
  // Diagnose the node
14
- diagnoseJsxElement(node, typeChecker, original);
15
+ diagnoseJsxElement(ts, node, typeChecker, original);
15
16
  }
16
17
  });
17
18
  }
18
19
  exports.recursiveDiagnoseJsxElements = recursiveDiagnoseJsxElements;
19
- function diagnoseJsxElement(node, typeChecker, diagnostics) {
20
+ function diagnoseJsxElement(ts, node, typeChecker, diagnostics) {
20
21
  const file = node.getSourceFile();
21
22
  const safeAttribute = getSafeAttribute(node.openingElement);
22
23
  // Safe mode warnings
@@ -25,9 +26,9 @@ function diagnoseJsxElement(node, typeChecker, diagnostics) {
25
26
  // Empty element
26
27
  node.children.length === 0 ||
27
28
  // Only text elements
28
- (node.children.length === 1 && node.children[0].kind === tsserverlibrary_1.default.SyntaxKind.JsxText)) {
29
+ (node.children.length === 1 && node.children[0].kind === ts.SyntaxKind.JsxText)) {
29
30
  diagnostics.push({
30
- category: tsserverlibrary_1.default.DiagnosticCategory.Warning,
31
+ category: ts.DiagnosticCategory.Warning,
31
32
  code: Errors.UnusedSafe.code,
32
33
  file,
33
34
  length: safeAttribute.end - safeAttribute.pos - 1,
@@ -37,10 +38,13 @@ function diagnoseJsxElement(node, typeChecker, diagnostics) {
37
38
  return;
38
39
  }
39
40
  for (const exp of node.children) {
41
+ if (
40
42
  // JSX Element inside safe
41
- if (tsserverlibrary_1.default.isJsxElement(exp)) {
43
+ ts.isJsxElement(exp) ||
44
+ // Element is using safe with escapeHtml
45
+ (ts.isJsxExpression(exp) && exp.expression?.getText().match(ESCAPE_HTML_REGEX))) {
42
46
  diagnostics.push({
43
- category: tsserverlibrary_1.default.DiagnosticCategory.Error,
47
+ category: ts.DiagnosticCategory.Error,
44
48
  code: Errors.DoubleEscape.code,
45
49
  file,
46
50
  length: exp.end - exp.pos,
@@ -50,17 +54,17 @@ function diagnoseJsxElement(node, typeChecker, diagnostics) {
50
54
  continue;
51
55
  }
52
56
  // Warn on unnecessary safe attributes
53
- if (tsserverlibrary_1.default.isJsxExpression(exp) &&
57
+ if (ts.isJsxExpression(exp) &&
54
58
  // has inner expression
55
59
  exp.expression &&
56
60
  // is expression safe
57
- isSafeAttribute(typeChecker.getTypeAtLocation(exp.expression), exp.expression) &&
61
+ isSafeAttribute(ts, typeChecker.getTypeAtLocation(exp.expression), exp.expression) &&
58
62
  // does not starts with unsafe
59
63
  !exp.expression.getText().startsWith('unsafe') &&
60
64
  // Avoids double warnings
61
65
  !diagnostics.some((d) => d.start === safeAttribute.pos + 1 && d.file === file)) {
62
66
  diagnostics.push({
63
- category: tsserverlibrary_1.default.DiagnosticCategory.Warning,
67
+ category: ts.DiagnosticCategory.Warning,
64
68
  code: Errors.UnusedSafe.code,
65
69
  file,
66
70
  length: safeAttribute.end - safeAttribute.pos - 1,
@@ -74,7 +78,7 @@ function diagnoseJsxElement(node, typeChecker, diagnostics) {
74
78
  }
75
79
  // Look for expressions
76
80
  for (const exp of node.children) {
77
- if (!tsserverlibrary_1.default.isJsxExpression(exp)) {
81
+ if (!ts.isJsxExpression(exp)) {
78
82
  continue;
79
83
  }
80
84
  // Should always have an expression
@@ -83,49 +87,57 @@ function diagnoseJsxElement(node, typeChecker, diagnostics) {
83
87
  }
84
88
  const type = typeChecker.getTypeAtLocation(exp.expression);
85
89
  // Safe can be ignored
86
- if (isSafeAttribute(type, exp.expression)) {
90
+ if (isSafeAttribute(ts, type, exp.expression)) {
87
91
  continue;
88
92
  }
89
93
  // Arrays should be handled by the recursive function
90
94
  if (typeChecker.isArrayLikeType(type)) {
91
95
  let hasInnerJsx = false;
92
- tsserverlibrary_1.default.forEachChild(exp.expression, function loopSourceNodes(node) {
96
+ ts.forEachChild(exp.expression, function loopSourceNodes(node) {
93
97
  // Check first to early exit
94
- if (tsserverlibrary_1.default.isJsxElement(node)) {
98
+ if (ts.isJsxElement(node)) {
95
99
  hasInnerJsx = true;
96
100
  return;
97
101
  }
98
- tsserverlibrary_1.default.forEachChild(node, loopSourceNodes);
102
+ ts.forEachChild(node, loopSourceNodes);
99
103
  });
100
104
  // Skips diagnostics if there is an inner JSX element
101
105
  if (hasInnerJsx) {
102
106
  continue;
103
107
  }
104
108
  }
109
+ // Switch between component and element xss errors
110
+ const error = node.openingElement.tagName.getText().match(UPPERCASE)
111
+ ? Errors.ComponentXss
112
+ : Errors.Xss;
105
113
  diagnostics.push({
106
- category: tsserverlibrary_1.default.DiagnosticCategory.Error,
107
- code: Errors.Xss.code,
114
+ category: ts.DiagnosticCategory.Error,
115
+ code: error.code,
108
116
  file,
109
117
  length: exp.end - exp.pos,
110
- messageText: Errors.Xss.message,
118
+ messageText: error.message,
111
119
  start: exp.pos
112
120
  });
113
121
  }
114
122
  return;
115
123
  }
116
124
  exports.diagnoseJsxElement = diagnoseJsxElement;
117
- function isSafeAttribute(type, expression) {
125
+ function isSafeAttribute(ts, type, expression) {
118
126
  // We allow literal string types here, as if they have XSS content,
119
127
  // the user has explicitly written it
120
128
  if (
121
129
  // Non string types cannot have XSS values
122
- !(type.flags & tsserverlibrary_1.default.TypeFlags.String) &&
130
+ !(type.flags & ts.TypeFlags.String) &&
123
131
  // Objects may have toString() overridden
124
- !(type.flags & tsserverlibrary_1.default.TypeFlags.Object)) {
132
+ !(type.flags & ts.TypeFlags.Object)) {
125
133
  return true;
126
134
  }
135
+ const text = expression.getText();
136
+ if (
127
137
  // Variables starting with safe are suppressed
128
- if (expression.getText().startsWith('safe')) {
138
+ text.startsWith('safe') ||
139
+ // Starts with a call to a escapeHtml function name
140
+ text.match(ESCAPE_HTML_REGEX)) {
129
141
  return true;
130
142
  }
131
143
  return false;
package/dist/util.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"util.js","sourceRoot":"","sources":["../src/util.ts"],"names":[],"mappings":";;;;AAAA,6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,EAAE;QACrD,IAAI,SAAS,CAAC,OAAO,EAAE,KAAK,MAAM,EAAE;YAClC,OAAO,SAAS,CAAC;SAClB;KACF;IAED,OAAO,SAAS,CAAC;AACnB,CAAC;AARD,4CAQC;AAED,SAAgB,WAAW,CAAmB,GAAM;IAClD,MAAM,KAAK,GAAM,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC;IAErC,KAAK,IAAI,CAAC,IAAI,MAAM,CAAC,IAAI,CAAC,GAAG,CAAmB,EAAE;QAChD,MAAM,CAAC,GAAG,GAAG,CAAC,CAAC,CAAE,CAAC;QAClB,yEAAyE;QACzE,KAAK,CAAC,CAAC,CAAC,GAAG,CAAC,GAAG,IAAe,EAAE,EAAE,CAAC,CAAC,CAAC,KAAK,CAAC,GAAG,EAAE,IAAI,CAAC,CAAC;KACvD;IAED,OAAO,KAAK,CAAC;AACf,CAAC;AAVD,kCAUC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kitajs/ts-html-plugin",
3
- "version": "1.0.1",
3
+ "version": "1.0.2",
4
4
  "description": "Typescript LSP extension to catch XSS vulnerabilities.",
5
5
  "bugs": "https://github.com/kitajs/ts-html-plugin/issues",
6
6
  "repository": "https://github.com/kitajs/ts-html-plugin",