The RBS files seem like a weird compromise to me. I I'm not sure I see the practical benefit, but maybe someone who has used .d.ts files can explain it. Is it just helpful if your IDE has tooling to use it? Seems like it could be helpful, but also sounds like it will become an annoying "code quality" hoop those of us that don't use VSCode will have to jump through for little benefit. When you read code outside of you…
If there was a way to do a type signatures inline without making things ugly, I would use them. Optionally enforcing @param and @return comments would be good enough for me. A separate file is useless for me because I don’t use an IDE.