You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Oct 2, 2024. It is now read-only.
Copy file name to clipboardExpand all lines: README.md
+10-8Lines changed: 10 additions & 8 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -124,16 +124,18 @@ Each `SchemaMap` is configured this way:
124
124
125
125
| Option | Default value | Description |
126
126
| - | - | - |
127
-
| `output` | | Relative path to output the generated code. It should end with `.graphql.dart` or else the generator will need to generate one more file. |
128
-
| `schema` | | Relative path to the GraphQL schema. | | `queries_glob` | | Glob that selects all query files to be used
129
-
with this schema. | | `naming_scheme` | `pathedWithTypes` | The naming scheme to be used on generated classes
130
-
names. `pathedWithTypes` is the default for retrocompatibility, where the names of previous types are used as prefix of
131
-
the next class. This can generate duplication on certain schemas. With `pathedWithFields`, the names of previous fields
132
-
are used as prefix of the next class and with `simple`, only the actual GraphQL class nameis considered. |
133
-
| `type_name_field` | `__typename` | The name of the field used to differentiate interfaces and union types (
127
+
| `output` | | Relative path to output the generated code. It should end with `.graphql.dart` or else the generator will
128
+
need to generate one more file. | | `schema` | | Relative path to the GraphQL schema. | | `queries_glob` | | Glob that
129
+
selects all query files to be used with this schema. | | `naming_scheme` | `pathedWithTypes` | The naming scheme to be
130
+
used on generated classes names. `pathedWithTypes` is the default for retrocompatibility, where the names of previous
131
+
types are used as prefix of the next class. This can generate duplication on certain schemas. With `pathedWithFields`,
132
+
the names of previous fields are used as prefix of the next class and with `simple`, only the actual GraphQL class
133
+
nameis considered. | | `type_name_field` | `__typename` | The name of the field used to differentiate interfaces and
134
+
union types (
134
135
commonly `__typename` or `__resolveType`). Note that `__typename` field are not added automatically to the query. If you
135
136
want interface/union type resolution, you need to manually add it there or set `append_type_name` to `true`. |
136
-
| `append_type_name` | `false` | Appends `type_name_field` value to the query selections set. |
137
+
| `append_type_name` | `false` | Appends `type_name_field` value to the query selections set. | | `fragments_glob`
138
+
| `null` | Import path to the file implementing fragments for all queries mapped in schema_mapping. |
137
139
138
140
See [examples](./example) for more information and configuration options.
0 commit comments