File tree Expand file tree Collapse file tree 2 files changed +17
-0
lines changed Expand file tree Collapse file tree 2 files changed +17
-0
lines changed Original file line number Diff line number Diff line change @@ -47,6 +47,7 @@ const create = context => {
47
47
)
48
48
|| ( node . parent . type === 'Property' && ! node . parent . computed && node . parent . key === node )
49
49
|| ( node . parent . type === 'JSXAttribute' && node . parent . value === node )
50
+ || ( node . parent . type === 'TSEnumMember' && ( node . parent . initializer === node || node . parent . id === node ) )
50
51
) {
51
52
return ;
52
53
}
Original file line number Diff line number Diff line change @@ -38,3 +38,19 @@ test.snapshot({
38
38
String . raw `const foo = "foo \\x46";` ,
39
39
] ,
40
40
} ) ;
41
+
42
+ test . typescript ( {
43
+ valid : [
44
+ outdent `
45
+ enum Files {
46
+ Foo = "C:\\\\path\\\\to\\\\foo.js",
47
+ }
48
+ ` ,
49
+ outdent `
50
+ enum Foo {
51
+ "\\\\a\\\\b" = "baz",
52
+ }
53
+ ` ,
54
+ ] ,
55
+ invalid : [ ] ,
56
+ } ) ;
You can’t perform that action at this time.
0 commit comments