#19: JavaScript Tutorial | Factory Function in JavaScript

preview_player
Показать описание
The Factory Function is similar to constructor functions/class functions, but instead of using new to create an object, factory functions simply creates an object and returns it.
Factory Functions are a very useful tool in JavaScript. Factory Functions in JavaScript are similar to constructor functions/class functions, but they do not require the use of the ‘this‘ keyword for inner values or the use of the ‘new‘ keyword when instantiating new objects. Factory Functions can contain inner values, methods, etc. just like normal regular functions. Factory Functions differ from regular functions as they always return an object, which will contain any value, method.
Рекомендации по теме
Комментарии
Автор

Great video as always, keep up the good work 👍

katiedodd
Автор

Subscribed to your channel, I will follow the growth. I think you have a great future

naomihoward