Skip to content

Commit

Permalink
refactor(vite): rename
Browse files Browse the repository at this point in the history
  • Loading branch information
yoyo930021 committed Oct 4, 2022
1 parent 02eb1b0 commit e313edd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/vite/src/node/plugins/asset.ts
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ export function assetPlugin(config: ResolvedConfig): Plugin {
id = id.replace(urlRE, '$1').replace(/[\?&]$/, '')
const url = await fileToUrl(id, config, this)
if (isEmitAssetsWithModule) {
return `import img from ${JSON.stringify(url)};export default img;`
return `import asset from ${JSON.stringify(url)};export default asset;`
}
return `export default ${JSON.stringify(url)}`
},
Expand Down

0 comments on commit e313edd

Please sign in to comment.