diff --git a/packages/typescript-estree/README.md b/packages/typescript-estree/README.md index 9cbcb2727cfc..7eb267d10dd3 100644 --- a/packages/typescript-estree/README.md +++ b/packages/typescript-estree/README.md @@ -101,14 +101,6 @@ interface ParseOptions { * Set to true to create a top-level array containing all tokens from the file. */ tokens?: boolean; - - /* - * The JSX AST changed the node type for string literals - * inside a JSX Element from `Literal` to `JSXText`. - * When value is `true`, these nodes will be parsed as type `JSXText`. - * When value is `false`, these nodes will be parsed as type `Literal`. - */ - useJSXTextNode?: boolean; } const PARSE_DEFAULT_OPTIONS: ParseOptions = { @@ -120,7 +112,6 @@ const PARSE_DEFAULT_OPTIONS: ParseOptions = { loggerFn: undefined, range: false, tokens: false, - useJSXTextNode: false, }; declare function parse( diff --git a/packages/typescript-estree/src/ast-converter.ts b/packages/typescript-estree/src/ast-converter.ts index 33c8f9fbc5e5..465a0b955c47 100644 --- a/packages/typescript-estree/src/ast-converter.ts +++ b/packages/typescript-estree/src/ast-converter.ts @@ -25,7 +25,6 @@ export function astConverter( */ const instance = new Converter(ast, { errorOnUnknownASTType: extra.errorOnUnknownASTType || false, - useJSXTextNode: extra.useJSXTextNode || false, shouldPreserveNodeMaps, }); diff --git a/packages/typescript-estree/src/convert.ts b/packages/typescript-estree/src/convert.ts index ffacd1d8a8fd..9847df945901 100644 --- a/packages/typescript-estree/src/convert.ts +++ b/packages/typescript-estree/src/convert.ts @@ -36,7 +36,6 @@ const SyntaxKind = ts.SyntaxKind; interface ConverterOptions { errorOnUnknownASTType: boolean; - useJSXTextNode: boolean; shouldPreserveNodeMaps: boolean; } @@ -2246,32 +2245,17 @@ export class Converter { }); } - /** - * The JSX AST changed the node type for string literals - * inside a JSX Element from `Literal` to `JSXText`. We - * provide a flag to support both types until `Literal` - * node type is deprecated in ESLint v5. - */ case SyntaxKind.JsxText: { const start = node.getFullStart(); const end = node.getEnd(); const text = this.ast.text.slice(start, end); - if (this.options.useJSXTextNode) { - return this.createNode(node, { - type: AST_NODE_TYPES.JSXText, - value: unescapeStringLiteralText(text), - raw: text, - range: [start, end], - }); - } else { - return this.createNode(node, { - type: AST_NODE_TYPES.Literal, - value: unescapeStringLiteralText(text), - raw: text, - range: [start, end], - }); - } + return this.createNode(node, { + type: AST_NODE_TYPES.JSXText, + value: unescapeStringLiteralText(text), + raw: text, + range: [start, end], + }); } case SyntaxKind.JsxSpreadAttribute: diff --git a/packages/typescript-estree/src/parser-options.ts b/packages/typescript-estree/src/parser-options.ts index 55f47ef9041d..fdd71cc55b55 100644 --- a/packages/typescript-estree/src/parser-options.ts +++ b/packages/typescript-estree/src/parser-options.ts @@ -27,7 +27,6 @@ export interface Extra { strict: boolean; tokens: null | TSESTree.Token[]; tsconfigRootDir: string; - useJSXTextNode: boolean; moduleResolver: string; } @@ -100,14 +99,6 @@ interface ParseOptions { * Set to true to create a top-level array containing all tokens from the file. */ tokens?: boolean; - - /* - * The JSX AST changed the node type for string literals - * inside a JSX Element from `Literal` to `JSXText`. - * When value is `true`, these nodes will be parsed as type `JSXText`. - * When value is `false`, these nodes will be parsed as type `Literal`. - */ - useJSXTextNode?: boolean; } interface ParseAndGenerateServicesOptions extends ParseOptions { diff --git a/packages/typescript-estree/src/parser.ts b/packages/typescript-estree/src/parser.ts index e61b1b69ec2b..1692bd74e722 100644 --- a/packages/typescript-estree/src/parser.ts +++ b/packages/typescript-estree/src/parser.ts @@ -129,7 +129,6 @@ function resetExtra(): void { strict: false, tokens: null, tsconfigRootDir: process.cwd(), - useJSXTextNode: false, /** * Unless we can reliably infer otherwise, we default to assuming that this run could be part * of a long-running session (e.g. in an IDE) and watch programs will therefore be required @@ -251,17 +250,6 @@ function applyParserOptionsToExtra(options: TSESTreeOptions): void { extra.filePath = getFileName(extra); } - /** - * The JSX AST changed the node type for string literals - * inside a JSX Element from `Literal` to `JSXText`. - * - * When value is `true`, these nodes will be parsed as type `JSXText`. - * When value is `false`, these nodes will be parsed as type `Literal`. - */ - if (typeof options.useJSXTextNode === 'boolean' && options.useJSXTextNode) { - extra.useJSXTextNode = true; - } - /** * Allow the user to cause the parser to error if it encounters an unknown AST Node Type * (used in testing) diff --git a/packages/typescript-estree/src/ts-estree/estree-to-ts-node-types.ts b/packages/typescript-estree/src/ts-estree/estree-to-ts-node-types.ts index 0f74c42ac64f..b75485ec8238 100644 --- a/packages/typescript-estree/src/ts-estree/estree-to-ts-node-types.ts +++ b/packages/typescript-estree/src/ts-estree/estree-to-ts-node-types.ts @@ -100,7 +100,6 @@ export interface EstreeToTsNodeTypes { | ts.StringLiteral | ts.NumericLiteral | ts.RegularExpressionLiteral - | ts.JsxText | ts.NullLiteral | ts.BooleanLiteral | ts.BigIntLiteral; diff --git a/packages/typescript-estree/tests/ast-alignment/parse.ts b/packages/typescript-estree/tests/ast-alignment/parse.ts index 7a463d97256b..f19c94a38f31 100644 --- a/packages/typescript-estree/tests/ast-alignment/parse.ts +++ b/packages/typescript-estree/tests/ast-alignment/parse.ts @@ -49,7 +49,6 @@ function parseWithTypeScriptESTree(text: string, jsx = true): parser.AST { range: true, tokens: false, comment: false, - useJSXTextNode: true, errorOnUnknownASTType: true, /** * Babel will always throw on these types of issues, so we enable diff --git a/packages/typescript-estree/tests/lib/convert.test.ts b/packages/typescript-estree/tests/lib/convert.test.ts index b26390b7f750..74ce08aa9673 100644 --- a/packages/typescript-estree/tests/lib/convert.test.ts +++ b/packages/typescript-estree/tests/lib/convert.test.ts @@ -27,7 +27,6 @@ describe('convert', () => { const instance = new Converter(ast, { errorOnUnknownASTType: false, - useJSXTextNode: false, shouldPreserveNodeMaps: false, }); expect(instance.convertProgram()).toMatchSnapshot(); @@ -38,7 +37,6 @@ describe('convert', () => { const instance = new Converter(ast, { errorOnUnknownASTType: false, - useJSXTextNode: false, shouldPreserveNodeMaps: false, }) as any; @@ -50,7 +48,6 @@ describe('convert', () => { const instance = new Converter(ast, { errorOnUnknownASTType: false, - useJSXTextNode: false, shouldPreserveNodeMaps: false, }) as any; @@ -62,7 +59,6 @@ describe('convert', () => { const instance = new Converter(ast, { errorOnUnknownASTType: false, - useJSXTextNode: false, shouldPreserveNodeMaps: false, }) as any; @@ -76,7 +72,6 @@ describe('convert', () => { const instance = new Converter(ast, { errorOnUnknownASTType: false, - useJSXTextNode: false, shouldPreserveNodeMaps: false, }) as any; expect(instance.deeplyCopy(ast)).toMatchSnapshot(); @@ -87,7 +82,6 @@ describe('convert', () => { const instance = new Converter(ast, { errorOnUnknownASTType: true, - useJSXTextNode: false, shouldPreserveNodeMaps: false, }) as any; @@ -106,7 +100,6 @@ describe('convert', () => { const instance = new Converter(ast, { errorOnUnknownASTType: false, - useJSXTextNode: false, shouldPreserveNodeMaps: true, }); instance.convertProgram(); @@ -140,7 +133,6 @@ describe('convert', () => { const instance = new Converter(ast, { errorOnUnknownASTType: false, - useJSXTextNode: false, shouldPreserveNodeMaps: true, }); instance.convertProgram(); @@ -173,7 +165,6 @@ describe('convert', () => { const instance = new Converter(ast, { errorOnUnknownASTType: false, - useJSXTextNode: false, shouldPreserveNodeMaps: true, }); const program = instance.convertProgram(); @@ -205,7 +196,6 @@ describe('convert', () => { const ast = convertCode(''); const instance = new Converter(ast, { errorOnUnknownASTType: false, - useJSXTextNode: false, shouldPreserveNodeMaps: true, }); @@ -250,7 +240,6 @@ describe('convert', () => { const instance = new Converter(ast, { errorOnUnknownASTType: false, - useJSXTextNode: false, shouldPreserveNodeMaps: false, }); expect(() => instance.convertProgram()).toThrow( diff --git a/packages/typescript-estree/tests/lib/semanticInfo.test.ts b/packages/typescript-estree/tests/lib/semanticInfo.test.ts index d099342c72e7..ccce1f6e4c8d 100644 --- a/packages/typescript-estree/tests/lib/semanticInfo.test.ts +++ b/packages/typescript-estree/tests/lib/semanticInfo.test.ts @@ -28,7 +28,6 @@ function createOptions(fileName: string): TSESTreeOptions & { cwd?: string } { tokens: true, comment: true, jsx: false, - useJSXTextNode: false, errorOnUnknownASTType: true, filePath: fileName, tsconfigRootDir: path.join(process.cwd(), FIXTURES_DIR), diff --git a/packages/typescript-estree/tests/snapshots/comments/jsx-attr-and-text-with-url.src.js.shot b/packages/typescript-estree/tests/snapshots/comments/jsx-attr-and-text-with-url.src.js.shot index 23e257d45f1d..0313f535de1d 100644 --- a/packages/typescript-estree/tests/snapshots/comments/jsx-attr-and-text-with-url.src.js.shot +++ b/packages/typescript-estree/tests/snapshots/comments/jsx-attr-and-text-with-url.src.js.shot @@ -42,7 +42,7 @@ Object { 61, ], "raw": "http://example.com", - "type": "Literal", + "type": "JSXText", "value": "http://example.com", }, ], diff --git a/packages/typescript-estree/tests/snapshots/comments/jsx-block-comment.src.js.shot b/packages/typescript-estree/tests/snapshots/comments/jsx-block-comment.src.js.shot index f4155967a745..851f8980ab51 100644 --- a/packages/typescript-estree/tests/snapshots/comments/jsx-block-comment.src.js.shot +++ b/packages/typescript-estree/tests/snapshots/comments/jsx-block-comment.src.js.shot @@ -48,7 +48,7 @@ Object { ], "raw": " ", - "type": "Literal", + "type": "JSXText", "value": " ", }, @@ -103,7 +103,7 @@ Object { ], "raw": " ", - "type": "Literal", + "type": "JSXText", "value": " ", }, diff --git a/packages/typescript-estree/tests/snapshots/comments/jsx-generic-with-comment-in-tag.src.js.shot b/packages/typescript-estree/tests/snapshots/comments/jsx-generic-with-comment-in-tag.src.js.shot index 01c1a39e231f..cbf278f9ee7b 100644 --- a/packages/typescript-estree/tests/snapshots/comments/jsx-generic-with-comment-in-tag.src.js.shot +++ b/packages/typescript-estree/tests/snapshots/comments/jsx-generic-with-comment-in-tag.src.js.shot @@ -43,7 +43,7 @@ Object { ], "raw": " ", - "type": "Literal", + "type": "JSXText", "value": " ", }, @@ -190,7 +190,7 @@ Object { ], "raw": " ", - "type": "Literal", + "type": "JSXText", "value": " ", }, @@ -374,7 +374,7 @@ Object { ], "raw": " ", - "type": "Literal", + "type": "JSXText", "value": " ", }, @@ -558,7 +558,7 @@ Object { ], "raw": " ", - "type": "Literal", + "type": "JSXText", "value": " ", }, @@ -779,7 +779,7 @@ Object { "raw": " ", - "type": "Literal", + "type": "JSXText", "value": " ", @@ -927,7 +927,7 @@ Object { ], "raw": " ", - "type": "Literal", + "type": "JSXText", "value": " ", }, @@ -1111,7 +1111,7 @@ Object { ], "raw": " ", - "type": "Literal", + "type": "JSXText", "value": " ", }, @@ -1295,7 +1295,7 @@ Object { ], "raw": " ", - "type": "Literal", + "type": "JSXText", "value": " ", }, @@ -1515,7 +1515,7 @@ Object { ], "raw": " ", - "type": "Literal", + "type": "JSXText", "value": " ", }, diff --git a/packages/typescript-estree/tests/snapshots/comments/jsx-tag-comments.src.js.shot b/packages/typescript-estree/tests/snapshots/comments/jsx-tag-comments.src.js.shot index e14584d71e3f..177f12a16625 100644 --- a/packages/typescript-estree/tests/snapshots/comments/jsx-tag-comments.src.js.shot +++ b/packages/typescript-estree/tests/snapshots/comments/jsx-tag-comments.src.js.shot @@ -48,7 +48,7 @@ Object { ], "raw": " ", - "type": "Literal", + "type": "JSXText", "value": " ", }, diff --git a/packages/typescript-estree/tests/snapshots/comments/jsx-text-with-multiline-non-comment.src.js.shot b/packages/typescript-estree/tests/snapshots/comments/jsx-text-with-multiline-non-comment.src.js.shot index dce1129ff0f1..34ae0afe27e7 100644 --- a/packages/typescript-estree/tests/snapshots/comments/jsx-text-with-multiline-non-comment.src.js.shot +++ b/packages/typescript-estree/tests/snapshots/comments/jsx-text-with-multiline-non-comment.src.js.shot @@ -51,7 +51,7 @@ Object { * test */ ", - "type": "Literal", + "type": "JSXText", "value": " /** * test diff --git a/packages/typescript-estree/tests/snapshots/comments/jsx-text-with-url.src.js.shot b/packages/typescript-estree/tests/snapshots/comments/jsx-text-with-url.src.js.shot index c0b9bcc60388..b51fc4edf9ce 100644 --- a/packages/typescript-estree/tests/snapshots/comments/jsx-text-with-url.src.js.shot +++ b/packages/typescript-estree/tests/snapshots/comments/jsx-text-with-url.src.js.shot @@ -42,7 +42,7 @@ Object { 37, ], "raw": "http://example.com", - "type": "Literal", + "type": "JSXText", "value": "http://example.com", }, ], @@ -208,7 +208,7 @@ Object { 81, ], "raw": "http://example.com", - "type": "Literal", + "type": "JSXText", "value": "http://example.com", }, ], @@ -392,7 +392,7 @@ Object { 130, ], "raw": "http://example.com", - "type": "Literal", + "type": "JSXText", "value": "http://example.com", }, ], @@ -649,7 +649,7 @@ Object { 190, ], "raw": "http://example.com", - "type": "Literal", + "type": "JSXText", "value": "http://example.com", }, ], @@ -849,7 +849,7 @@ Object { 238, ], "raw": "http://example.com", - "type": "Literal", + "type": "JSXText", "value": "http://example.com", }, ], diff --git a/packages/typescript-estree/tests/snapshots/comments/jsx-with-greather-than.src.js.shot b/packages/typescript-estree/tests/snapshots/comments/jsx-with-greather-than.src.js.shot index b2ccc72ae26e..308c14521e5e 100644 --- a/packages/typescript-estree/tests/snapshots/comments/jsx-with-greather-than.src.js.shot +++ b/packages/typescript-estree/tests/snapshots/comments/jsx-with-greather-than.src.js.shot @@ -157,7 +157,7 @@ Object { 61, ], "raw": "//", - "type": "Literal", + "type": "JSXText", "value": "//", }, ], diff --git a/packages/typescript-estree/tests/snapshots/comments/jsx-with-operators.src.js.shot b/packages/typescript-estree/tests/snapshots/comments/jsx-with-operators.src.js.shot index 623f6422eedb..2d5c27d4fe04 100644 --- a/packages/typescript-estree/tests/snapshots/comments/jsx-with-operators.src.js.shot +++ b/packages/typescript-estree/tests/snapshots/comments/jsx-with-operators.src.js.shot @@ -157,7 +157,7 @@ Object { 61, ], "raw": "//", - "type": "Literal", + "type": "JSXText", "value": "//", }, ], diff --git a/packages/typescript-estree/tests/snapshots/jsx-useJSXTextNode/self-closing-tag-inside-tag.src.js.shot b/packages/typescript-estree/tests/snapshots/jsx-useJSXTextNode/self-closing-tag-inside-tag.src.js.shot index f19079709bf4..2e6300509975 100644 --- a/packages/typescript-estree/tests/snapshots/jsx-useJSXTextNode/self-closing-tag-inside-tag.src.js.shot +++ b/packages/typescript-estree/tests/snapshots/jsx-useJSXTextNode/self-closing-tag-inside-tag.src.js.shot @@ -23,7 +23,7 @@ Object { ], "raw": " ", - "type": "Literal", + "type": "JSXText", "value": " ", }, @@ -101,7 +101,7 @@ Object { ], "raw": " ", - "type": "Literal", + "type": "JSXText", "value": " ", }, diff --git a/packages/typescript-estree/tests/snapshots/jsx-useJSXTextNode/test-content.src.js.shot b/packages/typescript-estree/tests/snapshots/jsx-useJSXTextNode/test-content.src.js.shot index 7a64b57e9dac..326c3194f956 100644 --- a/packages/typescript-estree/tests/snapshots/jsx-useJSXTextNode/test-content.src.js.shot +++ b/packages/typescript-estree/tests/snapshots/jsx-useJSXTextNode/test-content.src.js.shot @@ -22,7 +22,7 @@ Object { 18, ], "raw": "@test content", - "type": "Literal", + "type": "JSXText", "value": "@test content", }, ], diff --git a/packages/typescript-estree/tests/snapshots/jsx/attributes.src.js.shot b/packages/typescript-estree/tests/snapshots/jsx/attributes.src.js.shot index 1c6978110358..0c7c49b765a7 100644 --- a/packages/typescript-estree/tests/snapshots/jsx/attributes.src.js.shot +++ b/packages/typescript-estree/tests/snapshots/jsx/attributes.src.js.shot @@ -22,7 +22,7 @@ Object { 39, ], "raw": "test", - "type": "Literal", + "type": "JSXText", "value": "test", }, ], diff --git a/packages/typescript-estree/tests/snapshots/jsx/element-keyword-name.src.js.shot b/packages/typescript-estree/tests/snapshots/jsx/element-keyword-name.src.js.shot index 9a3ca8aae026..a1526ac3de67 100644 --- a/packages/typescript-estree/tests/snapshots/jsx/element-keyword-name.src.js.shot +++ b/packages/typescript-estree/tests/snapshots/jsx/element-keyword-name.src.js.shot @@ -23,7 +23,7 @@ Object { ], "raw": " ", - "type": "Literal", + "type": "JSXText", "value": " ", }, @@ -101,7 +101,7 @@ Object { ], "raw": " ", - "type": "Literal", + "type": "JSXText", "value": " ", }, @@ -179,7 +179,7 @@ Object { ], "raw": " ", - "type": "Literal", + "type": "JSXText", "value": " ", }, @@ -257,7 +257,7 @@ Object { ], "raw": " ", - "type": "Literal", + "type": "JSXText", "value": " ", }, diff --git a/packages/typescript-estree/tests/snapshots/jsx/embedded-invalid-js-identifier.src.js.shot b/packages/typescript-estree/tests/snapshots/jsx/embedded-invalid-js-identifier.src.js.shot index 40d5fc4812c2..e67cf324a956 100644 --- a/packages/typescript-estree/tests/snapshots/jsx/embedded-invalid-js-identifier.src.js.shot +++ b/packages/typescript-estree/tests/snapshots/jsx/embedded-invalid-js-identifier.src.js.shot @@ -79,7 +79,7 @@ Object { 35, ], "raw": "7x invalid-js-identifier", - "type": "Literal", + "type": "JSXText", "value": "7x invalid-js-identifier", }, ], diff --git a/packages/typescript-estree/tests/snapshots/jsx/escape-patterns-unknown.src.js.shot b/packages/typescript-estree/tests/snapshots/jsx/escape-patterns-unknown.src.js.shot index 25cd76ed83d8..141520e983f4 100644 --- a/packages/typescript-estree/tests/snapshots/jsx/escape-patterns-unknown.src.js.shot +++ b/packages/typescript-estree/tests/snapshots/jsx/escape-patterns-unknown.src.js.shot @@ -409,7 +409,7 @@ Object { 70, ], "raw": "&abc;", - "type": "Literal", + "type": "JSXText", "value": "&abc;", }, ], @@ -537,7 +537,7 @@ Object { 92, ], "raw": "¬anentity;", - "type": "Literal", + "type": "JSXText", "value": "¬anentity;", }, ], @@ -665,7 +665,7 @@ Object { 105, ], "raw": "&#x;", - "type": "Literal", + "type": "JSXText", "value": "&#x;", }, ], diff --git a/packages/typescript-estree/tests/snapshots/jsx/escape-patterns-valid.src.js.shot b/packages/typescript-estree/tests/snapshots/jsx/escape-patterns-valid.src.js.shot index 2cc38d57adbe..1856270c740c 100644 --- a/packages/typescript-estree/tests/snapshots/jsx/escape-patterns-valid.src.js.shot +++ b/packages/typescript-estree/tests/snapshots/jsx/escape-patterns-valid.src.js.shot @@ -24,7 +24,7 @@ Object { "raw": "   ", - "type": "Literal", + "type": "JSXText", "value": "   ", diff --git a/packages/typescript-estree/tests/snapshots/jsx/escape-patters-multi.src.js.shot b/packages/typescript-estree/tests/snapshots/jsx/escape-patters-multi.src.js.shot index d3cff5df9bf9..cc3c38b714cd 100644 --- a/packages/typescript-estree/tests/snapshots/jsx/escape-patters-multi.src.js.shot +++ b/packages/typescript-estree/tests/snapshots/jsx/escape-patters-multi.src.js.shot @@ -22,7 +22,7 @@ Object { 44, ], "raw": "  test", - "type": "Literal", + "type": "JSXText", "value": "  test", }, ], diff --git a/packages/typescript-estree/tests/snapshots/jsx/multiple-blank-spaces.src.js.shot b/packages/typescript-estree/tests/snapshots/jsx/multiple-blank-spaces.src.js.shot index 9e5cd8c899c9..17fa0430b73c 100644 --- a/packages/typescript-estree/tests/snapshots/jsx/multiple-blank-spaces.src.js.shot +++ b/packages/typescript-estree/tests/snapshots/jsx/multiple-blank-spaces.src.js.shot @@ -22,7 +22,7 @@ Object { 7, ], "raw": " ", - "type": "Literal", + "type": "JSXText", "value": " ", }, ], diff --git a/packages/typescript-estree/tests/snapshots/jsx/namespaced-attribute-and-value-inserted.src.js.shot b/packages/typescript-estree/tests/snapshots/jsx/namespaced-attribute-and-value-inserted.src.js.shot index 647aa3f85b5e..cfb3f96c345d 100644 --- a/packages/typescript-estree/tests/snapshots/jsx/namespaced-attribute-and-value-inserted.src.js.shot +++ b/packages/typescript-estree/tests/snapshots/jsx/namespaced-attribute-and-value-inserted.src.js.shot @@ -22,7 +22,7 @@ Object { 16, ], "raw": " ", - "type": "Literal", + "type": "JSXText", "value": " ", }, Object { @@ -76,7 +76,7 @@ Object { 24, ], "raw": " ", - "type": "Literal", + "type": "JSXText", "value": " ", }, Object { diff --git a/packages/typescript-estree/tests/snapshots/jsx/self-closing-tag-inside-tag.src.js.shot b/packages/typescript-estree/tests/snapshots/jsx/self-closing-tag-inside-tag.src.js.shot index 373468554f63..cfb82c9a414f 100644 --- a/packages/typescript-estree/tests/snapshots/jsx/self-closing-tag-inside-tag.src.js.shot +++ b/packages/typescript-estree/tests/snapshots/jsx/self-closing-tag-inside-tag.src.js.shot @@ -23,7 +23,7 @@ Object { ], "raw": " ", - "type": "Literal", + "type": "JSXText", "value": " ", }, @@ -101,7 +101,7 @@ Object { ], "raw": " ", - "type": "Literal", + "type": "JSXText", "value": " ", }, diff --git a/packages/typescript-estree/tests/snapshots/jsx/tag-names-with-multi-dots-multi.src.js.shot b/packages/typescript-estree/tests/snapshots/jsx/tag-names-with-multi-dots-multi.src.js.shot index 9edf414fa882..7ef41034fc55 100644 --- a/packages/typescript-estree/tests/snapshots/jsx/tag-names-with-multi-dots-multi.src.js.shot +++ b/packages/typescript-estree/tests/snapshots/jsx/tag-names-with-multi-dots-multi.src.js.shot @@ -23,7 +23,7 @@ Object { ], "raw": " ", - "type": "Literal", + "type": "JSXText", "value": " ", }, @@ -345,7 +345,7 @@ Object { ], "raw": " ", - "type": "Literal", + "type": "JSXText", "value": " ", }, diff --git a/packages/typescript-estree/tests/snapshots/jsx/test-content.src.js.shot b/packages/typescript-estree/tests/snapshots/jsx/test-content.src.js.shot index b400dfee5ad0..4df5e2ed08b0 100644 --- a/packages/typescript-estree/tests/snapshots/jsx/test-content.src.js.shot +++ b/packages/typescript-estree/tests/snapshots/jsx/test-content.src.js.shot @@ -22,7 +22,7 @@ Object { 18, ], "raw": "@test content", - "type": "Literal", + "type": "JSXText", "value": "@test content", }, ], diff --git a/packages/typescript-estree/tests/snapshots/tsx/react-typed-props.src.tsx.shot b/packages/typescript-estree/tests/snapshots/tsx/react-typed-props.src.tsx.shot index 52271fbad013..c526bcc9da4a 100644 --- a/packages/typescript-estree/tests/snapshots/tsx/react-typed-props.src.tsx.shot +++ b/packages/typescript-estree/tests/snapshots/tsx/react-typed-props.src.tsx.shot @@ -231,7 +231,7 @@ Object { ], "raw": " ", - "type": "Literal", + "type": "JSXText", "value": " ", }, @@ -324,7 +324,7 @@ Object { ], "raw": " ", - "type": "Literal", + "type": "JSXText", "value": " ", },