ember-cli / ember-cli/broccoli-terser-sourcemap

Console spam when parsing inline sourcemaps

Open
#288 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
10
Forks
33
PR merge metrics
No merged PRs in 30d

Description

# Problem
When this addon encounters an inline sourcemap (`sourceMappingURL=data:application/json;charset=utf-8;base64,[giant base64 blob...]`), it fails to parse it and generates a huge console message containing the entire base64 blob.

# Cause
The `source-map-url` package used in this lib will return the entire inline sourcemap when you call `getFrom(code)`.

This becomes an issue in `get-sourcemap-content.js`, because it always assumes `getFrom(code)` returns a url.

The filesystem exists check fails, and a `console.warn` message fires off saying the `url` referenced could not be found. However this `url` is actually the huge inline sourcemap blob!

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.