@graphql-codegen/c-sharp-common
Version:
13 lines (12 loc) • 589 B
TypeScript
import { NameNode } from 'graphql';
/**
* Checks name against list of keywords. If it is, will prefix value with @
*
* Note:
* This class should first invoke the convertName from base-visitor to convert the string or node
* value according the naming configuration, eg upper or lower case. Then resulting string checked
* against the list or keywords.
* However the generated C# code is not yet able to handle fields that are in a different case so
* the invocation of convertName is omitted purposely.
*/
export declare function convertSafeName(node: NameNode | string): string;