DEV Community

Discussion on: 5 useful TypeScript tricks

Collapse
 
shadowtime2000 profile image
shadowtime2000 • Edited

I believe setters and getters are already available in plain javascript.

Collapse
 
basilebong profile image
Basile Bong • Edited

Hi,
Indeed Setters and Getters also exist in plain JS. Note that optional chaining has also been recently added to JS.
Thanks for the comment, I will edit my post to make this clear!