Skip to content

Commit

Permalink
fix: get metafile on windows
Browse files Browse the repository at this point in the history
  • Loading branch information
sxzz committed Jul 24, 2024
1 parent 2de6dd5 commit 048c93b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/plugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import type {
} from 'esbuild'
import type { Format, NormalizedOptions } from '.'
import type { Logger } from './log'
import type { MaybePromise } from './utils'
import { slash, type MaybePromise } from './utils'
import type { SourceMap } from 'rollup'

export type ChunkInfo = {
Expand Down Expand Up @@ -132,7 +132,7 @@ export class PluginContainer {
.filter((file) => !file.path.endsWith('.map'))
.map((file): ChunkInfo | AssetInfo => {
if (isJS(file.path) || isCSS(file.path)) {
const relativePath = path.relative(process.cwd(), file.path)
const relativePath = slash(path.relative(process.cwd(), file.path))
const meta = metafile?.outputs[relativePath]
return {
type: 'chunk',
Expand Down

0 comments on commit 048c93b

Please sign in to comment.