How to use the stringTypeAnnotation function from babel-types

Find comprehensive JavaScript babel-types.stringTypeAnnotation code examples handpicked from public code repositorys.

69
70
71
72
73
74
75
76
77
78
function transformGraphQLScalarType(type: GraphQLScalarType, state: State) {
  switch (state.customScalars[type.name] || type.name) {
    case 'ID':
    case 'String':
    case 'Url':
      return t.stringTypeAnnotation();
    case 'Float':
    case 'Int':
      return t.numberTypeAnnotation();
    case 'Boolean':
fork icon0
star icon10
watch icon3

+ 5 other calls in file

Other functions in babel-types

Sorted by popularity

function icon

babel-types.identifier is the most popular function in babel-types (4076 examples)