isValidCSharpIdentifier
Checks whether the provided name is a valid C# identifier (without @ prefix). Does not account for keyword conflicts — use isCSharpKeyword for that.
import { isValidCSharpIdentifier } from "@alloy-js/csharp";
function isValidCSharpIdentifier(name: string): boolean;Parameters
Section titled “Parameters”| name | string |
Returns
Section titled “Returns”booleantrue if the name matches C# identifier rules (letter or underscore start, word chars after).