diff --git a/1-js/11-async/01-callbacks/article.md b/1-js/11-async/01-callbacks/article.md index 8f9189ae3..335c02623 100644 --- a/1-js/11-async/01-callbacks/article.md +++ b/1-js/11-async/01-callbacks/article.md @@ -1,68 +1,68 @@ -# Introduction: callbacks +# Введення: колбеки -```warn header="We use browser methods in examples here" -To demonstrate the use of callbacks, promises and other abstract concepts, we'll be using some browser methods: specifically, loading scripts and performing simple document manipulations. +```warn header="У прикладах ми використовуємо методи браузера" +Щоб продемонструвати використання колбеків, промісів та інших абстрактних понять, ми будемо використовувати деякі методи браузера: зокрема, завантажувати скрипти та виконувати прості маніпуляції з документом. -If you're not familiar with these methods, and their usage in the examples is confusing, you may want to read a few chapters from the [next part](/document) of the tutorial. +Якщо ви не знайомі з цими методами, і їх використання в прикладах викликає заплутаність, ви можете прочитати кілька розділів з [наступної частини](/document) підручника. -Although, we'll try to make things clear anyway. There won't be anything really complex browser-wise. +Хоча ми все одно спробуємо все прояснити. У браузері не буде нічого складного. ``` -Many functions are provided by JavaScript host environments that allow you to schedule *asynchronous* actions. In other words, actions that we initiate now, but they finish later. +Багато функцій надаються середовищами JavaScript, які дозволяють планувати *асинхронні* дії. Тобто дії, які ми починаємо зараз, але закінчуємо пізніше. -For instance, one such function is the `setTimeout` function. +Наприклад, однією з таких функцій є `setTimeout`. -There are other real-world examples of asynchronous actions, e.g. loading scripts and modules (we'll cover them in later chapters). +Є й інші реальні приклади асинхронних дій, наприклад завантаження скриптів і модулів (ми розглянемо їх у наступних розділах). -Take a look at the function `loadScript(src)`, that loads a script with the given `src`: +Розгляньмо функцію `loadScript(src)`, яка завантажує скрипт із заданим `src`: ```js function loadScript(src) { - // creates a