Check if provided string is an
IdentifierName
as specified in ECMA262 edition 5.1 section 7.6.
yarn add @prettier/is-es5-identifier-name
import isEs5IdentifierName from "@prettier/is-es5-identifier-name";
isEs5IdentifierName("prettier");
// -> true
isEs5IdentifierName("16");
// -> false