Python is a different language, and follows a different philosophy. In Python, absolutely everything is public. You can't even hide variables in a closure like you can do in JavaScript, because in Python there's reflection methods to pull stuff out of a closure. This puts full power into the hands of the API users to (ab)use your library however they want. This also means every update a library makes will effectively be a breaking-change update (though, there's different levels of "breaking change", some updates will break code that was being bad and reaching into the library's internals when it shouldn't, others updates will break what's supposed to be the public API).
JavaScript follows a much more rigid philosophy, which I appreciate. When something is private in JavaScript, it's truely private, and I don't have to worry about something using reflection to get the value of my private data. I know with certainly that I can update how I store my private data, and know there's a 0% chance that I'm breaking other people's code. I can't do that in Python.
Now, in relation to the specific feature request you're proposing, you're basically asking for default parameters to become part of a function's public API. This means, if I have older code written like this:
function doThing(value) {
var value = value_ == null ? DEFAULT_VALUE : value_
...
}
I can't later refactor it to look like this, without doing a major-version update.
function doThing(value = DEFAULT_VALUE) {
...
}
Or, as an alternative example, say we want to add a new parameter to the function, which, when present will change the default value of another parameter. Like this.
// before
function doThing({ useSpecialMode = false } = {}) {
if (typeof useSpecialMode !== 'boolean') throw new Error('Bad param')
// ...
}
// after
function doThing({ useSpecialMode = null, specialModeKey = null } = {}) {
useSpecialMode ??= !!specialModeKey
if (typeof useSpecialMode !== 'boolean') throw new Error('Bad param')
// ...
}
This normally wouldn't be a breaking change, but if we make default parameters part of the public API, it would be.
There's also the fact that sometimes people are trying to run JavaScript in a locked-down secure enviornment (SES). The controller of this enviornment might expose an API in which others can use, but that's the only way they can communicate with the outside world. If that API had private, implementation details as a default parameter, and we suddenly made those default parameters public knowledge, then we may be providing these locked-down scripts a gateway to get out of their box. Other languages don't always have to support this ability to lock down a script the same way JavaScript needs to support it.