Skip to content

Commit e5747eb

Browse files
RomainLanzpi0
authored andcommittedMar 11, 2019
fix(types): correct Vuex Store instance (#227)
1 parent 56df825 commit e5747eb

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed
 

‎types/index.d.ts

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import { AxiosError, AxiosInstance, AxiosRequestConfig, AxiosResponse } from 'axios'
22
import Vue from 'vue'
3+
import './vuex'
34

45
interface NuxtAxiosInstance extends AxiosInstance {
56
$request<T = any>(config: AxiosRequestConfig): Promise<T>

‎types/vuex.d.ts

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
import { NuxtAxiosInstance } from '.'
2+
3+
declare module 'vuex' {
4+
interface Store<S> {
5+
$axios: NuxtAxiosInstance,
6+
}
7+
}

0 commit comments

Comments
 (0)
Please sign in to comment.