DEV Community

Discussion on: Objective JS with IIFE

Collapse
 
256hz profile image
Abe Dolinger

Makes sense! I didn't see it laid out in the post that this was specifically for older JS. Typescript gives you private and public methods at design time (i.e., private methods become public on compile, but won't compile if used improperly). Doesn't help if you're in a legacy codebase, but at least the possibility has existed for a while!