File tree Expand file tree Collapse file tree 12 files changed +17
-176
lines changed Expand file tree Collapse file tree 12 files changed +17
-176
lines changed Original file line number Diff line number Diff line change @@ -147,7 +147,6 @@ export type { TransformOptions as EsbuildTransformOptions } from 'esbuild'
147147export type { ESBuildOptions , ESBuildTransformResult } from './plugins/esbuild'
148148export type { Manifest , ManifestChunk } from './plugins/manifest'
149149export type { ResolveOptions , InternalResolveOptions } from './plugins/resolve'
150- export type { SplitVendorChunkCache } from './plugins/splitVendorChunk'
151150export type { TerserOptions } from './plugins/terser'
152151
153152export type {
Original file line number Diff line number Diff line change @@ -6,12 +6,13 @@ import {
66 escapeRegex ,
77 flattenId ,
88 isBuiltin ,
9+ isCSSRequest ,
910 isExternalUrl ,
1011 moduleListContains ,
1112 normalizePath ,
1213} from '../utils'
1314import { browserExternalId , optionalPeerDepId } from '../plugins/resolve'
14- import { isCSSRequest , isModuleCSSRequest } from '../plugins/css'
15+ import { isModuleCSSRequest } from '../plugins/css'
1516import type { Environment } from '../environment'
1617import { createBackCompatIdResolver } from '../idResolver'
1718
Original file line number Diff line number Diff line change @@ -71,6 +71,7 @@ import {
7171 getPackageManagerCommand ,
7272 getPkgName ,
7373 injectQuery ,
74+ isCSSRequest ,
7475 isDataUrl ,
7576 isExternalUrl ,
7677 isObject ,
@@ -256,9 +257,6 @@ type CssLang =
256257 | keyof typeof PreprocessLang
257258 | keyof typeof PostCssDialectLang
258259
259- export const isCSSRequest = ( request : string ) : boolean =>
260- CSS_LANGS_RE . test ( request )
261-
262260export const isModuleCSSRequest = ( request : string ) : boolean =>
263261 cssModuleRE . test ( request )
264262
Original file line number Diff line number Diff line change @@ -2,9 +2,8 @@ import { transform } from 'esbuild'
22import { TraceMap , decodedMap , encodedMap } from '@jridgewell/trace-mapping'
33import type { ResolvedConfig } from '../config'
44import type { Plugin } from '../plugin'
5- import { escapeRegex } from '../utils'
5+ import { escapeRegex , isCSSRequest } from '../utils'
66import type { Environment } from '../environment'
7- import { isCSSRequest } from './css'
87import { isHTMLRequest } from './html'
98
109const nonJsRe = / \. j s o n (?: $ | \? ) /
Original file line number Diff line number Diff line change @@ -17,6 +17,7 @@ import {
1717 encodeURIPath ,
1818 generateCodeFrame ,
1919 getHash ,
20+ isCSSRequest ,
2021 isDataUrl ,
2122 isExternalUrl ,
2223 normalizePath ,
@@ -40,7 +41,7 @@ import {
4041 publicAssetUrlRE ,
4142 urlToBuiltUrl ,
4243} from './asset'
43- import { cssBundleNameCache , isCSSRequest } from './css'
44+ import { cssBundleNameCache } from './css'
4445import { modulePreloadPolyfillId } from './modulePreloadPolyfill'
4546
4647interface ScriptAssetsUrl {
Original file line number Diff line number Diff line change @@ -36,6 +36,7 @@ import {
3636 getHash ,
3737 injectQuery ,
3838 isBuiltin ,
39+ isCSSRequest ,
3940 isDataUrl ,
4041 isDefined ,
4142 isExternalUrl ,
@@ -67,7 +68,7 @@ import {
6768} from '../../shared/utils'
6869import type { TransformPluginContext } from '../server/pluginContainer'
6970import { throwOutdatedRequest } from './optimizedDeps'
70- import { isCSSRequest , isDirectCSSRequest } from './css'
71+ import { isDirectCSSRequest } from './css'
7172import { browserExternalId } from './resolve'
7273import { serializeDefine } from './define'
7374import { WORKER_FILE_ID } from './worker'
Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -12,16 +12,12 @@ export {
1212 defaultAllowedOrigins ,
1313} from './constants'
1414export { version as esbuildVersion } from 'esbuild'
15- export {
16- splitVendorChunkPlugin ,
17- splitVendorChunk ,
18- isCSSRequest ,
19- } from './plugins/splitVendorChunk'
2015export {
2116 normalizePath ,
2217 mergeConfig ,
2318 mergeAlias ,
2419 createFilter ,
20+ isCSSRequest ,
2521 rollupVersion ,
2622} from './utils'
2723export { perEnvironmentPlugin } from './plugin'
Original file line number Diff line number Diff line change @@ -10,10 +10,9 @@ import type {
1010 InvokeSendData ,
1111} from '../../shared/invokeMethods'
1212import { CLIENT_DIR } from '../constants'
13- import { createDebugger , normalizePath } from '../utils'
13+ import { createDebugger , isCSSRequest , normalizePath } from '../utils'
1414import type { InferCustomEventPayload , ViteDevServer } from '..'
1515import { getHookHandler } from '../plugins'
16- import { isCSSRequest } from '../plugins/css'
1716import { isExplicitImportRequired } from '../plugins/importAnalysis'
1817import { getEnvFilesForMode } from '../env'
1918import type { Environment } from '../environment'
Original file line number Diff line number Diff line change @@ -32,6 +32,7 @@ import {
3232 fsPathFromId ,
3333 getHash ,
3434 injectQuery ,
35+ isCSSRequest ,
3536 isDevServer ,
3637 isJSRequest ,
3738 joinUrlSegments ,
@@ -40,7 +41,6 @@ import {
4041 stripBase ,
4142} from '../../utils'
4243import { checkPublicFile } from '../../publicDir'
43- import { isCSSRequest } from '../../plugins/css'
4444import { getCodeWithSourcemap , injectSourcesContent } from '../sourcemap'
4545import { cleanUrl , unwrapId , wrapId } from '../../../shared/utils'
4646import { getNodeAssetAttributes } from '../../assetSource'
You can’t perform that action at this time.
0 commit comments