File tree 2 files changed +2
-2
lines changed
2 files changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -222,7 +222,7 @@ export function importAnalysisPlugin(config: ResolvedConfig): Plugin {
222
222
// for relative js/css imports, inherit importer's version query
223
223
// do not do this for unknown type imports, otherwise the appended
224
224
// query can break 3rd party plugin's extension checks.
225
- if ( isRelative && ! / [ \? & ] i m p o r t \b / . test ( url ) ) {
225
+ if ( isRelative && ! / [ \? & ] i m p o r t = ? \b / . test ( url ) ) {
226
226
const versionMatch = importer . match ( DEP_VERSION_RE )
227
227
if ( versionMatch ) {
228
228
url = injectQuery ( url , versionMatch [ 1 ] )
Original file line number Diff line number Diff line change @@ -118,7 +118,7 @@ export const isJSRequest = (url: string): boolean => {
118
118
return false
119
119
}
120
120
121
- const importQueryRE = / ( \? | & ) i m p o r t (?: & | $ ) /
121
+ const importQueryRE = / ( \? | & ) i m p o r t = ? (?: & | $ ) /
122
122
const trailingSeparatorRE = / [ \? & ] $ /
123
123
export const isImportRequest = ( url : string ) : boolean => importQueryRE . test ( url )
124
124
You can’t perform that action at this time.
0 commit comments