Skip to content

Commit cd6c2a8

Browse files
authored
feat: expose createFilter util (#8562)
1 parent e2c000c commit cd6c2a8

File tree

6 files changed

+4
-9
lines changed

6 files changed

+4
-9
lines changed

packages/plugin-vue-jsx/package.json

-1
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,6 @@
3838
"@babel/core": "^7.18.2",
3939
"@babel/plugin-syntax-import-meta": "^7.10.4",
4040
"@babel/plugin-transform-typescript": "^7.18.4",
41-
"@rollup/pluginutils": "^4.2.1",
4241
"@vue/babel-plugin-jsx": "^1.1.1"
4342
},
4443
"devDependencies": {

packages/plugin-vue-jsx/src/index.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import * as babel from '@babel/core'
55
import jsx from '@vue/babel-plugin-jsx'
66
// @ts-expect-error missing type
77
import importMeta from '@babel/plugin-syntax-import-meta'
8-
import { createFilter, normalizePath } from '@rollup/pluginutils'
8+
import { createFilter, normalizePath } from 'vite'
99
import type { ComponentOptions } from 'vue'
1010
import type { Plugin } from 'vite'
1111
import type { Options } from './types'

packages/plugin-vue-jsx/src/types.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import type { VueJSXPluginOptions } from '@vue/babel-plugin-jsx'
2-
import type { FilterPattern } from '@rollup/pluginutils'
2+
import type { FilterPattern } from 'vite'
33

44
export interface FilterOptions {
55
include?: FilterPattern

packages/plugin-vue/package.json

-3
Original file line numberDiff line numberDiff line change
@@ -47,8 +47,5 @@
4747
"source-map": "^0.6.1",
4848
"vite": "workspace:*",
4949
"vue": "^3.2.37"
50-
},
51-
"dependencies": {
52-
"@rollup/pluginutils": "^4.2.1"
5350
}
5451
}

packages/plugin-vue/src/index.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import fs from 'fs'
22
import type { Plugin, ViteDevServer } from 'vite'
3-
import { createFilter } from '@rollup/pluginutils'
3+
import { createFilter } from 'vite'
44
/* eslint-disable import/no-duplicates */
55
import type {
66
SFCBlock,

packages/plugin-vue/src/main.ts

+1-2
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
import path from 'path'
22
import type { SFCBlock, SFCDescriptor } from 'vue/compiler-sfc'
33
import type { PluginContext, SourceMap, TransformPluginContext } from 'rollup'
4-
import { normalizePath } from '@rollup/pluginutils'
54
import type { RawSourceMap } from 'source-map'
65
import type { EncodedSourceMap as TraceEncodedSourceMap } from '@jridgewell/trace-mapping'
76
import { TraceMap, eachMapping } from '@jridgewell/trace-mapping'
87
import type { EncodedSourceMap as GenEncodedSourceMap } from '@jridgewell/gen-mapping'
98
import { addMapping, fromMap, toEncodedMap } from '@jridgewell/gen-mapping'
10-
import { transformWithEsbuild } from 'vite'
9+
import { normalizePath, transformWithEsbuild } from 'vite'
1110
import {
1211
createDescriptor,
1312
getPrevDescriptor,

0 commit comments

Comments
 (0)