Skip to content

Commit

Permalink
feat(types): add Context interface
Browse files Browse the repository at this point in the history
  • Loading branch information
mvrlin authored and pi0 committed Feb 11, 2019
1 parent 92edc6a commit 7f8952a
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions types/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,12 @@ interface NuxtAxiosInstance extends AxiosInstance {
onResponseError(callback: (error: AxiosError) => void): void
}

declare module '@nuxt/vue-app' {
interface Context {
$axios: NuxtAxiosInstance
}
}

declare module 'vue/types/vue' {
interface Vue {
$axios: NuxtAxiosInstance
Expand Down

0 comments on commit 7f8952a

Please sign in to comment.