File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -20,7 +20,7 @@ import {
2020} from './runtime/webpack'
2121import type { TMatchVariable } from './parser'
2222import type { IVueCSSVarsCtx , Options } from './types'
23-
23+ import type { Compiler } from 'webpack'
2424const unplugin = createUnplugin < Options > (
2525 ( options : Options = { } , meta ) : any => {
2626 const userOptions = initOption ( options )
@@ -88,7 +88,7 @@ const unplugin = createUnplugin<Options>(
8888 // handle hmr with vite
8989 vite : vitePlugin ( context ) ,
9090 // handle hmr with webpack
91- webpack ( compiler ) {
91+ webpack ( compiler : Compiler ) {
9292 webpackPlugin ( context , compiler )
9393 } ,
9494 } ,
Original file line number Diff line number Diff line change @@ -5,7 +5,7 @@ import { handleVBindVariable } from './handle-variable'
55import { handleInjectCss } from './handle-inject-css'
66import type { IVueCSSVarsCtx } from '../types'
77import type { MagicStringBase } from 'magic-string-ast'
8-
8+ import type { Compiler } from 'webpack'
99// TODO: unit test
1010export function transformPreWebpack (
1111 id : string ,
@@ -48,7 +48,7 @@ export function transformPostWebpack(
4848}
4949
5050// TODO: unit test
51- export const webpackPlugin = ( ctx : IVueCSSVarsCtx , compiler : any ) => {
51+ export const webpackPlugin = ( ctx : IVueCSSVarsCtx , compiler : Compiler ) => {
5252 // mark webpack hmr
5353 let modifiedFile = ''
5454 compiler . hooks . watchRun . tapAsync ( NAME , ( compilation1 , watchRunCallBack ) => {
You can’t perform that action at this time.
0 commit comments