Skip to content

import attributes with spaces in relative path filename breaks bundling #1679

Description

@thescientist13

What happened?

A very niche use case it seems, but writing a JSON module import with a space in the filename seems to break

import nightOwlTheme from "../../node_modules/monaco-themes/themes/Night Owl.json" with { type: "json" };
Image Image

Steps to reproduce

ProjectEvergreen/playground.wcc.dev#18

Environment

Greenwood v0.34.0-alpha.4

Additional Context

It seems the filename from Rollup is different from what Greenwood tries to match against
https://github.com/ProjectEvergreen/greenwood/blob/v0.34.0-alpha.4/packages/cli/src/config/rollup.config.js#L603

{
  fileName: 'Night_20Owl.DNWUUwJF.json',
  asset: 'Night%20Owl.json',
  hash: 'DNWUUwJF'
}

Metadata

Metadata

Labels

Type

No fields configured for Bug.

Projects

Status
✅ Done

Relationships

None yet

Development

No branches or pull requests

Issue actions