Live data from Hacker News

How devtools map minified JS code back to your TypeScript source code

polarsignals.com

11–18 of 18 posts

Re: How devtools map minified JS code back to your TypeScript source code

#11
post #4

Earlier quoted context omitted.

Offset is difference from a starting point or a previous position

“Offset” is not enough on its own. Offset from what? Start of file? Absolute offset. Previous offset? Relative offset.

2nd order offset. The offset from the

Re: How devtools map minified JS code back to your TypeScript source code

#12
post #2

> Notice how the decoded values give relative positions, each value represents the difference from the previous position, not absolute coordinates. This is crucial: instead of encoding large column numbers like 27698 in minified files, source maps only store small deltas like +7 or +15, making the encoded strings much more compact. Wouldn't "offset" be a more apt term?

Delta and offset mean the same thing — the difference between two amounts.

Delta is perhaps slightly more obscure outside of a math setting. Perhaps.

Re: How devtools map minified JS code back to your TypeScript source code

#13

Earlier quoted context omitted.

“Offset” is not enough on its own. Offset from what? Start of file? Absolute offset. Previous offset? Relative offset.

2nd order offset. The offset from the

perhaps the delta between offsets

Re: How devtools map minified JS code back to your TypeScript source code

#14
post #9
post #2

> Notice how the decoded values give relative positions, each value represents the difference from the previous position, not absolute coordinates. This is crucial: instead of encoding large column numbers like 27698 in minified files, source maps only store small deltas like +7 or +15, making the encoded strings much more compact. Wouldn't "offset" be a more apt term?

Delta Encoding is the common term

Agreed... Delta Encoding, or even Delta Offset would work together.

Re: How devtools map minified JS code back to your TypeScript source code

#16
post #2

> Notice how the decoded values give relative positions, each value represents the difference from the previous position, not absolute coordinates. This is crucial: instead of encoding large column numbers like 27698 in minified files, source maps only store small deltas like +7 or +15, making the encoded strings much more compact. Wouldn't "offset" be a more apt term?

Delta and offset mean the same thing — the difference between two amounts. Delta is perhaps slightly more obscure outside of a math setting. Perhaps.

I feel like choosing the synonym that happens to be one letter shorter when the operation is literally intended to track things in a way that's more conscise is about as "apt" as it could be!
Post reply on HN