isValidIdentifier function

bool isValidIdentifier(
  1. String identifer
)

Returns true if this identifier is valid.

Implementation

bool isValidIdentifier(String identifer) =>
    RegExp(r'^[A-Za-z_][A-Za-z0-9_]*$').hasMatch(identifer);