Skip to content

Sourcemap for local files is absolute path #26

@shgysk8zer0

Description

@shgysk8zer0

Describe the bug
If scripts use import.meta and are local files, the soucemap contains the absolute filepath.
e.g. /home/${username}/Projects/${project}/${path}

To Reproduce
Steps to reproduce the behavior:

  1. Use import.meta.url or import.meta.resolve() in a local script
  2. Run rollup with rollupImport() and rollupImportMeta()
  3. Open in a browser
  4. See sources/Debugger panel

Expected behavior
The source should not be file://...

Additional context
Need to get back the original id or something, not use the transformed id

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Projects

Status

Backlog

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions