How to use the tsStringKeyword function from @babel/types
Find comprehensive JavaScript @babel/types.tsStringKeyword code examples handpicked from public code repositorys.
39 40 41 42 43 44 45 46 47 48
if (schema.enum) { return t.tsUnionType( schema.enum.map((variant) => t.tsLiteralType(t.stringLiteral(variant))), ); } return t.tsStringKeyword(); // add enum }, number(_schema) { return t.tsNumberKeyword();
2
14
2
+ 23 other calls in file
@babel/types.identifier is the most popular function in @babel/types (20936 examples)