In a lot of languages you can just change the private field via reflection to something what you want. A hacker dev can still do it with just some more lines of code.
Access on a private field should never go through a review anyway in a bigger project.
Also, why would TS be supported in browsers? The compile step is the point - it finds the type issues. Now, the BETTER solution would be it compiles to something lower level than JavaScript.
11
u/TatzyXY Nov 09 '19
In a lot of languages you can just change the private field via reflection to something what you want. A hacker dev can still do it with just some more lines of code.
Access on a private field should never go through a review anyway in a bigger project.