RUVIDEO
Поделитесь видео 🙏

JavaScript Bind Call Apply Explained

In this tutorial, we’ll take a look at the JavaScript bind call and apply functions and see how you can use them to ‘borrow’ functions from other objects.

Check out the previous tutorial on the ‘this’ keyword if you’re not quite sure about how that works: https://youtu.be/apE-9SEKxzE

JavaScript Bind Call Apply Explained
----------------------------------------------------------
00:00 Introduction
00:45 Basic example
01:41 JavaScript call example
02:44 JavaScript apply example
03:15 JavaScript bind example
03:56 More examples

— Follow Me —
Twitter: https://www.twitter.com/codebubb
Facebook: https://www.facebook.com/juniordevelopercentral/
Blog: https://www.juniordevelopercentral.com/
— Thanks! —

So once you have a hang of the JavaScript this keyword and how it can change it’s value depending on the execution context it is used in, understanding the JavaScript bind call apply functions is quite simple.

In this JavaScript tutorial, you’ll learn how to dynamically change the value of ‘this’ by passing in a new object to a specific JavaScript function.

This allows you to ‘borrow’ functions from other objects and use them to update properties or return new values (or do anything your heart desires!) with a different ‘this’ context.

This is a powerful technique allowing you to re-use code from other parts of your codebase and make your JavaScript code easier to maintain as the functions used by a JavaScript call function for example will only be needed once.

We’ll go through a couple of examples in the JavaScript tutorial and I’ll show you first how the JavaScript bind call apply functions work with some simple objects and you’ll see the main differences between call and apply as well as how the bind function in JavaScript works.

Don’t forget to check out the tutorial on the JavaScript this keyword first if you’re not sure about it: https://youtu.be/apE-9SEKxzE
You’ll need to have a pretty good idea of what ‘this’ is in JavaScript and how it’s value can change in different contexts. This will make understanding Javascript bind call and apply functions easier. Channel Handle @codebubb

Что делает видео по-настоящему запоминающимся? Наверное, та самая атмосфера, которая заставляет забыть о времени. Когда вы заходите на RUVIDEO, чтобы посмотреть онлайн «JavaScript Bind Call Apply Explained», вы рассчитываете на нечто большее, чем просто загрузку плеера. И мы это понимаем. Контент такого уровня заслуживает того, чтобы его смотрели в HD 1080, без дрожания картинки и бесконечного буферизации.

Честно говоря, Rutube сегодня — это кладезь уникальных находок, которые часто теряются в общем шуме. Мы же вытаскиваем на поверхность самое интересное. Будь то динамичный экшн, глубокий разбор темы от любимого автора или просто уютное видео для настроения — всё это доступно здесь бесплатно и без лишних формальностей. Никаких «заполните анкету, чтобы продолжить». Только вы, ваш экран и качественный поток.

Если вас зацепило это видео, не забудьте взглянуть на похожие материалы в блоке справа. Мы откалибровали наши алгоритмы так, чтобы они подбирали контент не просто «по тегам», а по настроению и смыслу. Ведь в конечном итоге, онлайн-кинотеатр — это не склад файлов, а место, где каждый вечер можно найти свою историю. Приятного вам отдыха на RUVIDEO!

Видео взято из открытых источников Rutube. Если вы правообладатель, обратитесь к первоисточнику.