Files
tsgo/testdata/baselines/reference/submodule/compiler/firstMatchRegExpMatchArray.js

19 lines
390 B
TypeScript

//// [tests/cases/compiler/firstMatchRegExpMatchArray.ts] ////
//// [firstMatchRegExpMatchArray.ts]
const match = ''.match(/ /)
if (match !== null) {
const foo: string = match[0]
const bar: string = match[1]
}
//// [firstMatchRegExpMatchArray.js]
"use strict";
const match = ''.match(/ /);
if (match !== null) {
const foo = match[0];
const bar = match[1];
}