Young Coder
Published in

Young Coder

Supporting Multiple Constructors in JavaScript

3 patterns for object creation

If your background is in a traditional object-oriented programming language, you might be thrown by the wild and sometimes lawless world of JavaScript. There are objects here — but they’re really prototypes, and all the syntax about classes and inheritance was bolted on in relatively recent versions. Some OO concepts still don’t fit…




Insights into the .NET stack. Thought pieces about the craft of software development. Real advice for teaching kids to code. And a shot of humor.

Recommended from Medium

Hacking Alexa

Understanding more about MVVM

Serverless: It’s not all a FaaS

Hunting for Data: a Few Words on Data Scraping

Enterprise resource planning software aren’t created equal.

It’s Time to Beta

The Best Way To Learn Python & Programming For A True Beginner

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Matthew MacDonald

Matthew MacDonald

Teacher, coder, long-ago Microsoft MVP. Author of heavy books. Join Young Coder for a creative take on science and technology. Queries:

More from Medium

How to Create and Manipulate DOM Nodes in Vanilla JS

[Fix] TypeError [ERR_INVALID_ARG_TYPE]: The “path” argument must be of type string.

Converting Object Oriented Code to Functional in JavaScript

Native Developer’s Web Development Notes