refactor: typings -> types

This commit is contained in:
草鞋没号
2021-11-08 20:16:09 +08:00
parent 2221092da5
commit 5622d32953
3 changed files with 0 additions and 0 deletions

24
types/assets.d.ts vendored Normal file
View File

@@ -0,0 +1,24 @@
declare module '*.png' {
const src: string
export default src
}
declare module '*.jpg' {
const src: string
export default src
}
declare module '*.gif' {
const src: string
export default src
}
declare module '*.webp' {
const src: string
export default src
}
declare module '*.svg' {
const src: string
export default src
}

16
types/global.d.ts vendored Normal file
View File

@@ -0,0 +1,16 @@
declare namespace NodeJS {
interface ProcessEnv {
readonly NODE_ENV: 'development' | 'production'
readonly PORT: string
}
}
interface Window {
/** 关闭预加载动画 */
removeLoading: () => void
/** NodeJs fs */
fs: typeof import('fs')
/** Electron ipcRenderer */
ipcRenderer: import('electron').IpcRenderer
}

5
types/shims-vue.d.ts vendored Normal file
View File

@@ -0,0 +1,5 @@
declare module '*.vue' {
import { DefineComponent } from 'vue'
const component: DefineComponent<{}, {}, any>
export default component
}