Skip to content

Instantly share code, notes, and snippets.

@bobsilverberg
Created March 5, 2018 21:53
Show Gist options
  • Save bobsilverberg/a680bab1169ee2b975f7af2c6a7b86ad to your computer and use it in GitHub Desktop.
Save bobsilverberg/a680bab1169ee2b975f7af2c6a7b86ad to your computer and use it in GitHub Desktop.
Error: src/amo/api/collections.js:217
v
217: return callApi({
218: auth: true,
219: body: {
...:
231: });
^ object literal. This type is incompatible with the expected param type of
95: }: CallApiParams): Promise<any> {
^^^^^^^^^^^^^ object type. See: src/core/api/index.js:95
Property `method` is incompatible:
229: method: `${action === 'create' ? 'POST' : 'PATCH'}`,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ string. This type is incompatible with
77: method?: 'GET' | 'POST' | 'DELETE' | 'HEAD' | 'OPTIONS' | 'PUT' | 'PATCH',
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ string enum. See: src/core/api/index.js:77
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment