I use keyword arguments in Python to minimize this pain. Instead of
create_user("Bob", True, False)
it's
create_user(name="Bob", admin=True, send_email=False)
JavaScript makes that more cumbersome with the object thing , but it's better than nothing.
I think a lot about the time a junior developer on the team was like "I'll use chat GPT to reverse this list" and I was just like my guy we're working in Python that's a one line expression.