Skip to content

Conversation

@kdy1
Copy link
Contributor

@kdy1 kdy1 commented Mar 25, 2024

The current code generates source map like

{
  "mappings": ";;UAAUA;MACOC,IAAI;IACV,SAASC;QACZC,QAAQC,GAAG,GAACH;IAChB;MAFgBC,IAAAA;AAGpB,GALUF,MAAAA",
  "names": [
    "A",
    "v",
    "a",
    "console",
    "log"
  ],
  "rangeMappings": ";;;;;;;;",
  "sources": [
    "../../input/index.ts"
  ],
  "sourcesContent": [
    "namespace A {\n    export const v = 25;\n    export function a() {\n        console.log(v);\n    }\n}\n"
  ],
  "version": 3
}

where rangeMappings is useless. This PR modifies the encoder to skip encoding if there's no meaningful data

Co-authored-by: Arpad Borsos <[email protected]>
@Swatinem Swatinem merged commit 51711b9 into getsentry:master Mar 26, 2024
@kdy1 kdy1 deleted the range-empty branch March 29, 2024 02:57
@kdy1 kdy1 restored the range-empty branch March 29, 2024 02:57
@kdy1 kdy1 deleted the range-empty branch March 29, 2024 02:57
@kdy1
Copy link
Contributor Author

kdy1 commented Mar 29, 2024

Can you publish a new version, please?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants