diff --git a/src/shared/type-predicates.ts b/src/shared/type-predicates.ts index 59eb888..7f2a90a 100644 --- a/src/shared/type-predicates.ts +++ b/src/shared/type-predicates.ts @@ -12,4 +12,4 @@ export const isNumericString = (x: string): boolean => JSON.stringify(+x) === x; // A predicate for a valid identifier export type Identifier = string; export const isIdentifier = (x: any): x is Identifier => - /[A-Za-z][A-Za-z0-9]*/i.test(x); \ No newline at end of file + /^[A-Za-z][A-Za-z0-9]*/i.test(x); \ No newline at end of file