3 ms·
> Notice how the decoded values give relative positions, each value represents the difference from the previous position, not absolute coordinates. This is cruc
by tantalor 1y ago
> 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?
- manojvivek 1y agoTo me, “offset” sounds more like the distance from the start, whereas here the values are relative to the previous segment. Not a native english speaker, so I could be wrong.
- tantalor 1y agoOffset is difference from a starting point or a previous position
- jagged-chisel 1y ago“Offset” is not enough on its own. Offset from what? Start of file? Absolute offset. Previous offset? Relative offset.
- willrshansen 1y ago2nd order offset. The offset from the <offset from the start of the file>
- eat_veggies 1y agoperhaps the delta between offsets
- jagged-chisel 1y agoWe’re gonna need the delta of deltas
- recursive 1y agoIt sounds equally apt to my ear. I've used both words for this concept in the past.
- deleted 1y ago[deleted]
- hanikesn 1y agoDelta Encoding is the common term
- tracker1 1y agoAgreed... Delta Encoding, or even Delta Offset would work together.
- accrual 1y agoIn this case I feel it's like six of one and a half-dozen of the other. Delta definition 4: (mathematics, physics, engineering) The symbol Δ; A change in a quantity, likely from "d" for "difference" Offset definition 7: The distance by which one thing is out of alignment with another. Got these from Wiktionary: * https://en.wiktionary.org/wiki/delta https://en.wiktionary.org/wiki/delta * https://en.wiktionary.org/wiki/offset https://en.wiktionary.org/wiki/offset
- paulddraper 1y agoDelta and offset mean the same thing — the difference between two amounts. Delta is perhaps slightly more obscure outside of a math setting. Perhaps.
- saghm 1y agoI 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!