It took me a bit of poking around to find it. The `source-map` library states that the version field is the version of the spec. https://github.com/mozilla/source-map#new-sourcemapconsumerrawsourcemap So your second guess is close. It's `version: 3` not as a default but because the generated map follows the 3rd revision of the spec.

I'd guess the library has version stored privately for internal use and doesn't want or expect external libs to access it or change it since it the library would need to output the data differently. It also doesn't seem that useful to say, set the version to 2.