DEV Community

Manuele J Sarfatti
Manuele J Sarfatti

Posted on

Your boat is sinking, you think you can make it to land, but you can only...

...save one flavour of JavaScript: OO or functional.

Which one do you bring with you and why?

Discussion (8)

Collapse
nicolus profile image
Nicolas Bailly

Typescript, which is the only sane way to do Object Oriented javascript.

Collapse
tobiassn profile image
Tobias SN

I give a Swimmer class to OOP and save functional.

Collapse
mjsarfatti profile image
Manuele J Sarfatti Author

πŸ˜‚

Collapse
khalyomede profile image
Khalyomede • Edited on

POP, because it offers runtime mutation of the code, I like it a lot

Collapse
mjsarfatti profile image
Manuele J Sarfatti Author

You mean OOP right?

Collapse
khalyomede profile image
Khalyomede

Nope, I mean prototype πŸ€“

Thread Thread
mjsarfatti profile image
Manuele J Sarfatti Author

Interesting 🧐

Collapse
nicholascloud profile image
Nicholas Cloud

Prototypal.