MCPcopy Create free account
hub / github.com/browserify/static-module / isIdentifierStart

Function isIdentifierStart

bench/input.js:71–79  ·  view source on GitHub ↗
(code, astral)

Source from the content-addressed store, hash-verified

69// Test whether a given character code starts an identifier.
70
71function isIdentifierStart(code, astral) {
72 if (code < 65) { return code === 36 }
73 if (code < 91) { return true }
74 if (code < 97) { return code === 95 }
75 if (code < 123) { return true }
76 if (code <= 0xffff) { return code >= 0xaa && nonASCIIidentifierStart.test(String.fromCharCode(code)) }
77 if (astral === false) { return false }
78 return isInAstralSet(code, astralIdentifierStartCodes)
79}
80
81// Test whether a given character is part of an identifier.
82

Callers 2

input.jsFile · 0.85
isRegExpIdentifierStartFunction · 0.85

Calls 1

isInAstralSetFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…