Remix.run Logo
zaptheimpaler 4 days ago

It's sort of Hyrum's Law but it's really just Go being Go. The error could've been an enum type that could be changed with only a string replace for consumers. Instead they are using strings as types, so now you have no idea how consumers might rely on it. They could check the middle 6 chars of the error and break if you change it. It's another terrible anachronistic design decision when better alternatives have been in use in other languages for decades. Early mistakes + inability to change things means you're stuck forever.

nitwit005 4 days ago | parent [-]

Yes, sadly, the comment is essentially incorrect. The strings were their official API in many cases.