Skip to content

Instantly share code, notes, and snippets.

@Markonis
Created March 18, 2019 16:07
Show Gist options
  • Save Markonis/3faad9053be2ee9704abf8a5a698049c to your computer and use it in GitHub Desktop.
Save Markonis/3faad9053be2ee9704abf8a5a698049c to your computer and use it in GitHub Desktop.
const api = {
create: new ApiEndpoint<Recipe, Recipe>(),
read: new ApiEndpoint<FindParams, Recipe>(),
update: new ApiEndpoint<Recipe, Recipe>(),
destroy: new ApiEndpoint<FindParams, undefined>(),
list: new ApiEndpoint<undefined, Recipe[]>()
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment