{"id":297696,"date":"2020-01-26T09:00:12","date_gmt":"2020-01-26T09:00:12","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=297696"},"modified":"-0001-11-30T00:00:00","modified_gmt":"2020-01-26T09:00:12","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=297696","title":{"rendered":"9 \u043f\u0440\u0438\u0435\u043c\u043e\u0432 \u0440\u0430\u0431\u043e\u0442\u044b \u0441 \u043e\u0431\u044a\u0435\u043a\u0442\u0430\u043c\u0438 \u0432 JavaScript \u0432 2020 \u0433\u043e\u0434\u0443"},"content":{"rendered":"\n<div class=\"post__text post__text-html\" id=\"post-content-body\" data-io-article-url=\"https:\/\/habr.com\/ru\/post\/485478\/\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/df\/qu\/nw\/dfqunwkjczd_kruso0cb-xon_-c.jpeg\"><br \/>  \u0410\u0432\u0442\u043e\u0440 \u0444\u043e\u0442\u043e \u2014 <a href=\"https:\/\/unsplash.com\/@jesuskiteque\" rel=\"nofollow\">Jesus Kiteque<\/a>.<\/p>\n<p>  \u0414\u043e\u0431\u0440\u043e\u0433\u043e \u0432\u0440\u0435\u043c\u0435\u043d\u0438 \u0441\u0443\u0442\u043e\u043a, \u0434\u0440\u0443\u0437\u044c\u044f!<\/p>\n<p>  \u041f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u044f\u044e \u0412\u0430\u0448\u0435\u043c\u0443 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u044e \u043f\u0435\u0440\u0435\u0432\u043e\u0434 \u0441\u0442\u0430\u0442\u044c\u0438 jsmanifest <a href=\"https:\/\/medium.com\/better-programming\/9-ways-to-work-with-objects-in-javascript-in-2020-d772c29db429\" rel=\"nofollow\">\u00ab9 Ways to Work With Objects in JavaScript in 2020\u00bb<\/a>.<\/p>\n<h2>9 \u043f\u0440\u0438\u0435\u043c\u043e\u0432 \u0440\u0430\u0431\u043e\u0442\u044b \u0441 \u043e\u0431\u044a\u0435\u043a\u0442\u0430\u043c\u0438 \u0432 JavaScript \u0432 2020 \u0433\u043e\u0434\u0443<\/h2>\n<p>  JS, \u043a\u0430\u043a \u0438 \u043f\u0440\u043e\u0447\u0438\u0435 \u044f\u0437\u044b\u043a\u0438 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f, \u0438\u043c\u0435\u0435\u0442 \u043c\u043d\u043e\u0436\u0435\u0441\u0442\u0432\u043e \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u043e\u0432 \u0434\u043b\u044f \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f \u043a\u0430\u043a \u043f\u0440\u043e\u0441\u0442\u044b\u0445, \u0442\u0430\u043a \u0438 \u0441\u043b\u043e\u0436\u043d\u044b\u0445 \u0437\u0430\u0434\u0430\u0447. \u0414\u0430\u0432\u0430\u0439\u0442\u0435 \u043f\u043e\u0437\u043d\u0430\u043a\u043e\u043c\u0438\u043c\u0441\u044f \u0441 9 \u043f\u0440\u0438\u0435\u043c\u0430\u043c\u0438 \u0440\u0430\u0431\u043e\u0442\u044b \u0441 \u043e\u0431\u044a\u0435\u043a\u0442\u0430\u043c\u0438 \u0432 JS \u0432 2020 \u0433\u043e\u0434\u0443.<\/p>\n<p>  \u0417\u0430\u043c\u0435\u0447\u0430\u043d\u0438\u0435: \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0438\u0437 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u043d\u044b\u0445 \u043f\u0440\u0438\u0435\u043c\u043e\u0432 \u043f\u043e\u043a\u0430\u0436\u0443\u0442\u0441\u044f \u0412\u0430\u043c \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u044b\u043c\u0438, \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043e\u0447\u0435\u0432\u0438\u0434\u043d\u044b\u043c\u0438 (\u043f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u0445\u043e\u0440\u043e\u0448\u043e \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u044b), \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043f\u0440\u0438\u0432\u0435\u0434\u0435\u043d\u044b \u043f\u0440\u043e\u0441\u0442\u043e \u0434\u043b\u044f \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0438.<\/p>\n<p>  \u041a\u0430\u043a \u0431\u044b \u0442\u043e \u043d\u0438 \u0431\u044b\u043b\u043e, \u0435\u0441\u043b\u0438 \u0412\u0430\u043c \u043d\u0440\u0430\u0432\u0438\u0442\u0441\u044f \u043f\u0438\u0441\u0430\u0442\u044c \u043a\u043e\u0434 \u043d\u0430 JS, \u0412\u044b, \u043f\u043e\u0436\u0430\u043b\u0443\u0439, \u0441\u043e\u0433\u043b\u0430\u0441\u0438\u0442\u0435\u0441\u044c \u0441\u043e \u043c\u043d\u043e\u0439, \u0447\u0442\u043e \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0441 \u043e\u0431\u044a\u0435\u043a\u0442\u0430\u043c\u0438 \u043d\u0430\u043c\u043d\u043e\u0433\u043e \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u0435\u0439, \u0447\u0435\u043c \u0441 \u0434\u0440\u0443\u0433\u0438\u043c\u0438 \u0442\u0438\u043f\u0430\u043c\u0438.<br \/>  <a name=\"habracut\"><\/a>  <\/p>\n<h3>1. \u0421\u043e\u0437\u0434\u0430\u0442\u044c \u043f\u0443\u0441\u0442\u043e\u0439 \u043e\u0431\u044a\u0435\u043a\u0442<\/h3>\n<p>  \u0417\u043d\u0430\u0435\u0442\u0435 \u043b\u0438 \u0412\u044b, \u0447\u0442\u043e \u043c\u043e\u0436\u0435\u0442\u0435 \u0441\u043e\u0437\u0434\u0430\u0432\u0430\u0442\u044c \u043e\u0431\u044a\u0435\u043a\u0442\u044b \u0432 JS? \u041a\u043e\u043d\u0435\u0447\u043d\u043e, \u0437\u043d\u0430\u0435\u0442\u0435.<\/p>\n<p>  \u0410 \u0437\u043d\u0430\u0435\u0442\u0435 \u043b\u0438 \u0412\u044b, \u0447\u0442\u043e \u043c\u043e\u0436\u0435\u0442\u0435 \u0441\u043e\u0437\u0434\u0430\u0432\u0430\u0442\u044c \u043f\u0443\u0441\u0442\u044b\u0435 \u043e\u0431\u044a\u0435\u043a\u0442\u044b?<\/p>\n<p>  \u0412\u043e\u0442 \u043f\u0440\u0438\u043c\u0435\u0440:  <\/p>\n<pre><code class=\"javascript\">const myEmptyObject = {} <\/code><\/pre>\n<p>  \u0422\u0430\u043a \u043e\u0431\u044b\u0447\u043d\u043e \u0441\u043e\u0437\u0434\u0430\u044e\u0442\u0441\u044f \u043f\u0443\u0441\u0442\u044b\u0435 \u043e\u0431\u044a\u0435\u043a\u0442\u044b. \u041e\u0434\u043d\u0430\u043a\u043e \u0442\u0430\u043a\u043e\u0439 \u043e\u0431\u044a\u0435\u043a\u0442 \u043d\u0435 \u0441\u043e\u0432\u0441\u0435\u043c \u043f\u0443\u0441\u0442\u043e\u0439, \u043f\u043e\u0441\u043a\u043e\u043b\u044c\u043a\u0443 \u043d\u0430 \u0441\u0430\u043c\u043e\u043c \u0434\u0435\u043b\u0435 \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u0442 Object.create(Object.prototype). \u041f\u043e\u044d\u0442\u043e\u043c\u0443 \u0412\u0430\u0448 \u043e\u0431\u044a\u0435\u043a\u0442 \u0431\u0443\u0434\u0435\u0442 \u0438\u043c\u0435\u0442\u044c \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u0441\u0432\u043e\u0439\u0441\u0442\u0432\u0430\u043c Object.prototype, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u043d\u0430 \u0432\u0435\u0440\u0448\u0438\u043d\u0435 <a href=\"https:\/\/developer.mozilla.org\/ru\/docs\/Learn\/JavaScript\/%D0%9E%D0%B1%D1%8A%D0%B5%D0%BA%D1%82%D1%8B\/Object_prototypes\" rel=\"nofollow\">\u0446\u0435\u043f\u043e\u0447\u043a\u0438 \u043f\u0440\u043e\u0442\u043e\u0442\u0438\u043f\u043e\u0432<\/a>.<\/p>\n<p>  \u042d\u0442\u043e \u043e\u0437\u043d\u0430\u0447\u0430\u0435\u0442, \u0447\u0442\u043e \u0412\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043c\u0435\u0442\u043e\u0434 myEmptyObject.toString().<\/p>\n<p>  \u0414\u043b\u044f \u0442\u043e\u0433\u043e, \u0447\u0442\u043e\u0431\u044b \u0441\u043e\u0437\u0434\u0430\u0442\u044c \u043f\u043e-\u043d\u0430\u0441\u0442\u043e\u044f\u0449\u0435\u043c\u0443 \u043f\u0443\u0441\u0442\u043e\u0439 \u043e\u0431\u044a\u0435\u043a\u0442, \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0435:  <\/p>\n<pre><code class=\"javascript\">const myTrullyEmptyObject = Object.create(null) <\/code><\/pre>\n<p>  \u0423 \u0442\u0430\u043a\u043e\u0433\u043e \u043e\u0431\u044a\u0435\u043a\u0442\u0430 \u043d\u0435 \u0431\u0443\u0434\u0435\u0442 \u0441\u0432\u043e\u0439\u0441\u0442\u0432, \u043f\u043e\u043a\u0430 \u0412\u044b \u0438\u0445 \u0435\u043c\u0443 \u043d\u0435 \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u0435.<\/p>\n<p>  \u0412 99,99% \u0441\u043b\u0443\u0447\u0430\u0435\u0432 \u0443 \u043d\u0430\u0441 \u043d\u0435\u0442 \u043f\u0440\u0438\u0447\u0438\u043d\u044b \u00ab\u043e\u0442\u043a\u0430\u0437\u044b\u0432\u0430\u0442\u044c\u0441\u044f \u043e\u0442 \u0443\u0441\u043b\u0443\u0433\u00bb \u0431\u0430\u0437\u043e\u0432\u043e\u0433\u043e \u043f\u0440\u043e\u0442\u043e\u0442\u0438\u043f\u0430.<\/p>\n<h3>2. \u041e\u0431\u044a\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u0435 \u043e\u0431\u044a\u0435\u043a\u0442\u043e\u0432 (Object.assign)<\/h3>\n<p>  <\/p>\n<pre><code class=\"javascript\">const novice = {     username: 'henry123',     level: 10,     hp: 100 }  function transform(target) {     return Object.assign(target, {         fireBolt(player) {             player.hp -= 15             return this         },     }) }  const sorceress = transform(novice) const lucy = {     username: 'iamlucy',     level: 5,     hp: 100 }  sorceress.fireBolt(lucy) <\/code><\/pre>\n<p>  \u041a\u043e\u0433\u0434\u0430 \u0412\u044b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0435 Object.assign, \u0412\u0430\u043c \u043d\u0443\u0436\u0435\u043d \u0446\u0435\u043b\u0435\u0432\u043e\u0439 \u043e\u0431\u044a\u0435\u043a\u0442 (target), \u043a \u043a\u043e\u0442\u043e\u0440\u043e\u043c\u0443 \u0431\u0443\u0434\u0443\u0442 \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0442\u044c\u0441\u044f \u0441\u0432\u043e\u0439\u0441\u0442\u0432\u0430 \u0438\/\u0438\u043b\u0438 \u043c\u0435\u0442\u043e\u0434\u044b.<\/p>\n<p>  \u0426\u0435\u043b\u0435\u0432\u043e\u0439 \u043e\u0431\u044a\u0435\u043a\u0442 \u043f\u0435\u0440\u0435\u0434\u0430\u0435\u0442\u0441\u044f Object.assign \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u043f\u0435\u0440\u0432\u043e\u0433\u043e \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u0430. \u0412\u043e \u0432\u0442\u043e\u0440\u043e\u043c \u0438 \u043f\u043e\u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0445 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u0430\u0445 \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u044e\u0442\u0441\u044f \u0441\u0432\u043e\u0439\u0441\u0442\u0432\u0430 \u0438\/\u0438\u043b\u0438 \u043c\u0435\u0442\u043e\u0434\u044b, \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u043c\u044b\u0435 \u043a target.<\/p>\n<p>  \u0412\u043e\u0442 \u043a\u0430\u043a \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u0435\u0442 \u044d\u0442\u043e\u0442 \u043c\u0435\u0442\u043e\u0434 <a href=\"https:\/\/developer.mozilla.org\/ru\/docs\/Web\/JavaScript\/Reference\/Global_Objects\/Object\/assign\" rel=\"nofollow\">MDN<\/a>:  <\/p>\n<blockquote><p>\u041c\u0435\u0442\u043e\u0434 Object.assign() \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u0434\u043b\u044f \u043a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0439 \u0432\u0441\u0435\u0445 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0445 \u043f\u0435\u0440\u0435\u0447\u0438\u0441\u043b\u044f\u0435\u043c\u044b\u0445 \u0441\u0432\u043e\u0439\u0441\u0442\u0432 \u0438\u0437 \u043e\u0434\u043d\u043e\u0433\u043e \u0438\u043b\u0438 \u0431\u043e\u043b\u0435\u0435 \u0438\u0441\u0445\u043e\u0434\u043d\u044b\u0445 \u043e\u0431\u044a\u0435\u043a\u0442\u043e\u0432 \u0432 \u0446\u0435\u043b\u0435\u0432\u043e\u0439 \u043e\u0431\u044a\u0435\u043a\u0442. \u041f\u043e\u0441\u043b\u0435 \u043a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u043e\u043d \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u0435\u0442 \u0446\u0435\u043b\u0435\u0432\u043e\u0439 \u043e\u0431\u044a\u0435\u043a\u0442.<\/p><\/blockquote>\n<p>  <\/p>\n<h3>\u041e\u0431\u044a\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u0435 \u043e\u0431\u044a\u0435\u043a\u0442\u043e\u0432 (Spread Syntax)<\/h3>\n<p>  <\/p>\n<pre><code class=\"javascript\">const novice = {     username: 'henry123',     level: 10,     hp: 100 }  function transform(target) {     return {         ...target,         fireBolt(player) {             player.hp -= 15             return this         },     } }  const sorceress = transform(novice) const lucy = {     username: 'iamlucy',     level: 5,     hp: 100 }  sorceress.fireBolt(lucy) <\/code><\/pre>\n<p>  \u0417\u0434\u0435\u0441\u044c \u043c\u044b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440 spread (\u00ab\u0442\u0440\u043e\u0435\u0442\u043e\u0447\u0438\u0435\u00bb) \u0432 \u043e\u0431\u044a\u0435\u043a\u0442\u043d\u043e\u043c \u043b\u0438\u0442\u0435\u0440\u0430\u043b\u0435.<\/p>\n<p>  \u0422\u0430\u043a\u043e\u0439 \u0441\u043f\u043e\u0441\u043e\u0431 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f spread \u0431\u044b\u043b \u0432\u0432\u0435\u0434\u0435\u043d \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043e\u043c ECMAScript2018.<\/p>\n<p>  \u042d\u0442\u043e \u043d\u0435\u0432\u0435\u0440\u043e\u044f\u0442\u043d\u043e \u043f\u0440\u043e\u0441\u0442\u043e\u0439 \u0441\u043f\u043e\u0441\u043e\u0431 \u043e\u0431\u044a\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u044f \u043e\u0431\u044a\u0435\u043a\u0442\u043e\u0432, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0412\u0430\u0448\u0435\u043c\u0443 \u043a\u043e\u0434\u0443 \u043e\u0441\u0442\u0430\u0432\u0430\u0442\u044c\u0441\u044f \u0430\u043a\u043a\u0443\u0440\u0430\u0442\u043d\u044b\u043c \u0438 \u0447\u0438\u0442\u0430\u0431\u0435\u043b\u044c\u043d\u044b\u043c.<\/p>\n<p>  \u041f\u043e\u043c\u043d\u0438\u0442\u0435, \u0447\u0442\u043e \u043f\u0440\u0430\u0432\u0438\u043b\u0430 \u043e\u0431\u044a\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u044f \u043e\u0431\u044a\u0435\u043a\u0442\u043e\u0432 \u043e\u0441\u0442\u0430\u044e\u0442\u0441\u044f \u043f\u0440\u0435\u0436\u043d\u0438\u043c\u0438, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0412\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0442\u0430\u043a\u0438\u0435 \u0441\u0442\u0440\u0430\u043d\u043d\u044b\u0435 \u043a\u043e\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u0438, \u043a\u0430\u043a \u044d\u0442\u0430 (\u0441 \u0412\u0430\u0448\u0435\u0433\u043e \u043f\u043e\u0437\u0432\u043e\u043b\u0435\u043d\u0438\u044f, \u044f \u043e\u043f\u0443\u0449\u0443 \u0447\u0430\u0441\u0442\u044c \u0441\u0442\u0430\u0442\u044c\u0438, \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u0430\u0432\u0442\u043e\u0440 \u0432\u043e\u0441\u0445\u0438\u0449\u0430\u0435\u0442\u0441\u044f \u0444\u0443\u043d\u043a\u0446\u0438\u044f\u043c\u0438 \u043a\u0430\u043a \u043e\u0431\u044a\u0435\u043a\u0442\u0430\u043c\u0438 \u043f\u0435\u0440\u0432\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430 \u2014 \u043f\u0440\u0438\u043c. \u043f\u0435\u0440.):  <\/p>\n<pre><code class=\"javascript\">\/\/ \u043e\u0431\u044a\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u0435 IIFE import React from 'react' import {     EditIcon,     DeleteIcon,     ResetIcon,     TrashIcon,     UndoIcon, } from '..\/lib\/icons' import * as utils from '..\/utils'  export const ausioExts = ['mp3', 'mpa', 'ogg', 'wav']  const icons = {     edit: {         component: EditIcon,         onClick: () =&gt; alert('You clicked the edit component'),         name: 'edit',     },     delete: {         component: DeleteIcon,         name: 'delete',     },     \/\/ audio icons     \/\/ IIFE \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u0435\u0442 \u043e\u0431\u044a\u0435\u043a\u0442     ...(function() {         return audioExts.reduce((acc, ext) =&gt; {             acc[ext] = {                 component: MdAudioTrack,                 title: 'Audio Track'             }             return acc         })(),     }) } <\/code><\/pre>\n<p>  IIFE \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u0435\u0442 \u043e\u0431\u044a\u0435\u043a\u0442, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043e\u0431\u044a\u0435\u0434\u0438\u043d\u044f\u0435\u0442\u0441\u044f \u0441 \u043e\u0431\u044a\u0435\u043a\u0442\u043e\u043c icons. \u041d\u0430 \u0432\u044b\u0445\u043e\u0434\u0435 \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u043c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0435:  <\/p>\n<pre><code class=\"javascript\">export const audioExts = ['mp3', 'mpa', 'ogg', 'wav']  const icons = {     edit: {         component: EditIcon,         onClick: () =&gt; alert('You clicked the edit component'),         name: 'edit',     },     delete: {         component: DeleteIcon,         name: 'delete',     },     \/\/ \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u043e\u0431\u044a\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u044f     mp3: {         component: MdAudiotrack,         title: 'Audio Track',     },     mpa: {         component: MdAudiotrack,         title: 'Audio Track',     },     ogg: {         component: MdAudiotrack,         title: 'Audio Track',     },     wav: {         component: MdAudiotrack,         title: 'Audio Track',     }, } <\/code><\/pre>\n<p>  <\/p>\n<h3>\u041f\u0440\u043e\u0432\u0435\u0440\u043a\u0430 \u0441\u0432\u043e\u0439\u0441\u0442\u0432 \u043e\u0431\u044a\u0435\u043a\u0442\u0430<\/h3>\n<p>  \u041e\u0434\u043d\u0430 \u0438\u0437 \u0444\u0438\u0447, \u043f\u0440\u0438\u0432\u0435\u0434\u0448\u0438\u0445 \u0432 \u0432\u043e\u0441\u0442\u043e\u0440\u0433 \u0441\u043e\u043e\u0431\u0449\u0435\u0441\u0442\u0432\u043e JS-\u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u043e\u0432 (\u044f \u0432 \u044d\u0442\u043e\u043c \u0443\u0432\u0435\u0440\u0435\u043d), \u044d\u0442\u043e <a href=\"https:\/\/developer.mozilla.org\/en-US\/docs\/Web\/JavaScript\/Reference\/Operators\/Optional_chaining\" rel=\"nofollow\">\u043e\u043f\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u0430\u044f \u0446\u0435\u043f\u043e\u0447\u043a\u0430<\/a>. \u042d\u0442\u043e\u0442 \u043d\u043e\u0432\u044b\u0439 \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u043a\u0430\u043a \u0432\u043e\u043f\u0440\u043e\u0441\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0439 \u0437\u043d\u0430\u043a \u0441 \u0442\u043e\u0447\u043a\u043e\u0439 (?.), \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0447\u0438\u0442\u0430\u0442\u044c \u0441\u0432\u043e\u0439\u0441\u0442\u0432\u0430, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043d\u0430\u0445\u043e\u0434\u044f\u0442\u0441\u044f \u0433\u043b\u0443\u0431\u043e\u043a\u043e \u0432 \u0446\u0435\u043f\u043e\u0447\u043a\u0435 \u043e\u0431\u044a\u0435\u043a\u0442\u043e\u0432, \u0431\u0435\u0437 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e\u0441\u0442\u0438 \u043f\u0440\u043e\u0432\u0435\u0440\u044f\u0442\u044c \u0440\u0430\u0431\u043e\u0442\u043e\u0441\u043f\u043e\u0441\u043e\u0431\u043d\u043e\u0441\u0442\u044c \u043a\u0430\u0436\u0434\u043e\u0439 \u0441\u0441\u044b\u043b\u043a\u0438 (<a href=\"https:\/\/habr.com\/ru\/company\/ruvds\/blog\/353446\/\">\u0445\u043e\u0440\u043e\u0448\u0430\u044f \u0441\u0442\u0430\u0442\u044c\u044f<\/a> \u043d\u0430 \u0425\u0430\u0431\u0440\u0435, \u043f\u043e\u0441\u0432\u044f\u0449\u0435\u043d\u043d\u0430\u044f \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u0430\u043c ?., ?? \u0438 |&gt;; \u0440\u0430\u0431\u043e\u0442\u0430\u044e \u043d\u0430\u0434 \u043f\u0435\u0440\u0435\u0432\u043e\u0434\u043e\u043c \u0441\u0442\u0430\u0442\u044c\u0438, \u043f\u043e\u0441\u0432\u044f\u0449\u0435\u043d\u043d\u043e\u0439 \u043e\u043f\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u043e\u0439 \u0446\u0435\u043f\u043e\u0447\u043a\u0435 \u0438 \u043e\u0431\u044a\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u044e \u0441 null, \u0441\u043b\u0435\u0434\u0438\u0442\u0435 \u0437\u0430 \u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u044f\u043c\u0438 \u2014 \u043f\u0440\u0438\u043c. \u043f\u0435\u0440.).<\/p>\n<p>  \u042d\u0442\u043e \u043e\u0437\u043d\u0430\u0447\u0430\u0435\u0442, \u0447\u0442\u043e \u0435\u0441\u043b\u0438 \u043c\u044b \u0438\u043c\u0435\u0435\u043c \u0442\u0430\u043a\u043e\u0439 \u043e\u0431\u044a\u0435\u043a\u0442:  <\/p>\n<pre><code class=\"javascript\">const food = {     fruits: {         apple: {             dates: {                 expired: '2020-01-25'             },         },     }, } <\/code><\/pre>\n<p>  \u2026 \u043d\u0430\u043c \u0431\u043e\u043b\u044c\u0448\u0435 \u043d\u0435 \u043d\u0443\u0436\u043d\u043e \u043f\u0438\u0441\u0430\u0442\u044c \u0442\u0430\u043a\u043e\u0439 \u0441\u043a\u0443\u0447\u043d\u044b\u0439 \u043a\u043e\u0434:  <\/p>\n<pre><code class=\"javascript\">function getAppleExpirationDate(obj) {     if (food.fruits &amp;&amp; food.fruits.apple &amp;&amp; food.fruits.apple.dates) {         return food.fruits.apple.dates.expired     } } <\/code><\/pre>\n<p>  \u0412\u043c\u0435\u0441\u0442\u043e \u044d\u0442\u043e\u0433\u043e, \u043c\u044b \u043c\u043e\u0436\u0435\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043e\u043f\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u0443\u044e \u0446\u0435\u043f\u043e\u0447\u043a\u0443:  <\/p>\n<pre><code class=\"javascript\">function getAppleExpirationDate(obj) {     return food?.fruits?.apple?.dates?.expired } <\/code><\/pre>\n<p>  \u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u0434\u0430\u043d\u043d\u043e\u0433\u043e \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440\u0430 \u0434\u0435\u043b\u0430\u0435\u0442 \u043a\u043e\u0434 \u0431\u043e\u043b\u0435\u0435 \u0447\u0438\u0441\u0442\u044b\u043c.<\/p>\n<p>  \u0424\u0443\u043d\u043a\u0446\u0438\u044f \u0432\u0440\u043e\u0434\u0435 \u044d\u0442\u043e\u0439:  <\/p>\n<pre><code class=\"javascript\">function findFatDogs(dog, result = []) {     if (dog &amp;&amp; dog.children) {         return dog.children.reduce((acc, child) =&gt; {             if (child &amp;&amp; child.weight &gt; 100) {                 return acc.concat(child)             } else {                 return acc.concat(findFatDogs(child))             }         }, result)     }     return result } <\/code><\/pre>\n<p>  \u2026 \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u0430 \u0442\u0430\u043a (\u0441 \u043f\u043e\u0432\u044b\u0448\u0435\u043d\u0438\u0435\u043c \u0447\u0438\u0442\u0430\u0431\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u0438):  <\/p>\n<pre><code class=\"javascript\">function findFatDogs(dog, result = []) {     if (dog?.children) {         return dog.children.reduce((acc, child) =&gt; {             return child?.weight &gt; 100             ? acc.concat(child)             : acc.concat(findFatDogs(child))         }, result)     } } <\/code><\/pre>\n<p>  \u0417\u0430\u043f\u043e\u043c\u043d\u0438\u0442\u0435: \u0432 \u043d\u0430\u0441\u0442\u043e\u044f\u0449\u0435\u0435 \u0432\u0440\u0435\u043c\u044f \u043d\u0435 \u0432\u0441\u0435 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u044b \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u044e\u0442 \u044d\u0442\u0443 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c. \u041e\u0434\u043d\u0430\u043a\u043e \u0432\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c TypeScript (\u0438\u043b\u0438 Babel \u2014 \u043f\u0440\u0438\u043c. \u043f\u0435\u0440.).<\/p>\n<h3>5. \u0412\u044b\u0437\u043e\u0432 \u043e\u0431\u044a\u0435\u043a\u0442\u043e\u0432 \u043f\u043e\u0441\u0440\u0435\u0434\u0441\u0442\u0432\u043e\u043c \u043f\u0435\u0440\u0435\u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u044f \u043c\u0435\u0442\u043e\u0434\u0430 .toString()<\/h3>\n<p>  \u041a\u043e\u0433\u0434\u0430 \u043e\u0431\u044a\u0435\u043a\u0442\u044b \u043d\u0430\u0437\u043d\u0430\u0447\u0430\u044e\u0442\u0441\u044f \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u043a\u043b\u044e\u0447\u0435\u0439 \u043b\u0438\u0442\u0435\u0440\u0430\u043b\u043e\u0432 \u043e\u0431\u044a\u0435\u043a\u0442\u0430, \u043e\u043d\u0438 \u0441\u0442\u0430\u043d\u043e\u0432\u044f\u0442\u0441\u044f \u0441\u0442\u0440\u043e\u043a\u0430\u043c\u0438. \u042d\u0442\u043e \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 \u043d\u0430\u043c \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u044b\u0435 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u0438.<\/p>\n<p>  \u0414\u0430\u0432\u0430\u0439\u0442\u0435 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u044d\u0442\u043e \u043d\u0430 \u043f\u0440\u0438\u043c\u0435\u0440\u0435:  <\/p>\n<pre><code class=\"javascript\">function Command(name, execute){     this.name = name     this.execute = execute }  Command.prototype.toString = function(){     return this.name }  const createCommandHub = function(){     const commands = {}     return {         add(command){             commands[command.name] = command         },         execute(command, ...args){             return commands[command].execute(...args)         },     } }  const cmds = createCommandHub() const talkCommand = new Command('talk', function(wordsToSay){     console.log(wordsToSay) }) const destroyEverythingCommand = new Command('destroyEverything', function(){     throw new Error('Destroying everything') })  cmds.add(talkCommand) cmds.add(destroyEverythingCommand) cmds.execute(talkCommand, 'Is talking a talent?') <\/code><\/pre>\n<p>  \u0415\u0441\u043b\u0438 \u0412\u044b \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u0435 \u044d\u0442\u043e\u0442 \u0441\u043d\u0438\u043f\u043f\u0435\u0442, \u0442\u043e \u0443\u0431\u0435\u0434\u0438\u0442\u0435\u0441\u044c \u0432 \u0442\u043e\u043c, \u0447\u0442\u043e \u043a\u043e\u0434 \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442, \u0430 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u043e\u043c \u0431\u0443\u0434\u0435\u0442 \u00abIs talking a talent?\u00bb<\/p>\n<p>  \u0415\u0441\u043b\u0438 \u043f\u0440\u0438\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c\u0441\u044f \u0432\u043d\u0438\u043c\u0430\u0442\u0435\u043b\u044c\u043d\u0435\u0435 \u043a \u0442\u043e\u043c\u0443, \u043a\u0430\u043a \u043c\u044b \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u043c \u043a\u043e\u043c\u0430\u043d\u0434\u0443, \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u0434\u0443\u043c\u0430\u0442\u044c, \u0447\u0442\u043e \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u0431\u0440\u043e\u0448\u0435\u043d\u0430 \u043e\u0448\u0438\u0431\u043a\u0430.<\/p>\n<p>  \u041f\u0440\u0438\u0447\u0438\u043d\u0430, \u043f\u043e \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u044d\u0442\u043e\u0433\u043e \u043d\u0435 \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u0442, \u0437\u0430\u043a\u043b\u044e\u0447\u0430\u0435\u0442\u0441\u044f \u0432 \u0442\u043e\u043c, \u0447\u0442\u043e \u043c\u044b \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u043b\u0438 \u043a\u043e\u043d\u0441\u0442\u0440\u0443\u043a\u0442\u043e\u0440 Command \u0438 \u043f\u0435\u0440\u0435\u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u043b\u0438 \u043c\u0435\u0442\u043e\u0434 toString.<\/p>\n<p>  \u041a\u043e\u0433\u0434\u0430 \u00ab\u043d\u0435\u043f\u0440\u0438\u043c\u0438\u0442\u0438\u0432\u00bb \u043d\u0430\u0437\u043d\u0430\u0447\u0430\u0435\u0442\u0441\u044f \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0441\u0432\u043e\u0439\u0441\u0442\u0432\u0430 \u043e\u0431\u044a\u0435\u043a\u0442\u0430, JS \u043f\u044b\u0442\u0430\u0435\u0442\u0441\u044f \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u0442\u044c \u0435\u0433\u043e \u0432 \u0441\u0442\u0440\u043e\u043a\u0443 \u043f\u0435\u0440\u0435\u0434 \u043d\u0430\u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435\u043c \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u043a\u043b\u044e\u0447\u0430, \u043e\u0431\u0440\u0430\u0449\u0430\u044f\u0441\u044c \u043a \u043c\u0435\u0442\u043e\u0434\u0443 .toString \u043f\u0440\u043e\u0442\u043e\u0442\u0438\u043f\u0430.<\/p>\n<h3>6. \u0414\u0435\u0441\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u0438\u0437\u0430\u0446\u0438\u044f<\/h3>\n<p>  \u0421\u0440\u0435\u0434\u0438 \u0434\u0440\u0443\u0433\u0438\u0445 \u0437\u0430\u043c\u0435\u0447\u0430\u0442\u0435\u043b\u044c\u043d\u044b\u0445 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u0435\u0439 \u044f\u0437\u044b\u043a\u0430 \u0441\u043b\u0435\u0434\u0443\u0435\u0442 \u043d\u0430\u0437\u0432\u0430\u0442\u044c \u0434\u0435\u0441\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u0438\u0437\u0430\u0446\u0438\u044e (\u043f\u0430\u0440\u043e\u0447\u043a\u0443 \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u044b\u0445 \u043f\u0440\u0438\u043c\u0435\u0440\u043e\u0432 \u0434\u0435\u0441\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u0438\u0437\u0430\u0446\u0438\u0438 \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c <a href=\"https:\/\/habr.com\/ru\/post\/483822\/\">\u0437\u0434\u0435\u0441\u044c<\/a> \u2014 \u043f\u0440\u0438\u043c. \u043f\u0435\u0440.):  <\/p>\n<pre><code class=\"javascript\">const obj = {     foods: {         fruits: ['apple', 'orange'],     }, }  const { foods } = obj  console.log(foods) \/\/ fruits: ['apple', 'orange'] <\/code><\/pre>\n<p>  <\/p>\n<h3>7. \u0418\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0435 \u043d\u0430\u0437\u0432\u0430\u043d\u0438\u044f \u0434\u0435\u0441\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u0438\u0440\u0443\u0435\u043c\u044b\u0445 \u0441\u0432\u043e\u0439\u0441\u0442\u0432<\/h3>\n<p>  <\/p>\n<pre><code class=\"javascript\">const obj = {     foods: {         fruits: ['apple', 'orange'],     }, }  const { foods: myFoods } = obj  console.log(myFoods) \/\/ fruits: ['apple', 'orange'] <\/code><\/pre>\n<p>  <\/p>\n<h3>8. \u041f\u0435\u0440\u0435\u0431\u043e\u0440 \u043a\u043b\u044e\u0447\u0435\u0439 \u043e\u0431\u044a\u0435\u043a\u0442\u0430 (for in)<\/h3>\n<p>  \u041b\u0435\u0433\u043a\u0438\u043c \u0441\u043f\u043e\u0441\u043e\u0431\u043e\u043c \u043f\u0435\u0440\u0435\u0447\u0438\u0441\u043b\u0438\u0442\u044c \u043a\u043b\u044e\u0447\u0438 \u043e\u0431\u044a\u0435\u043a\u0442\u0430 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f for in:  <\/p>\n<pre><code class=\"javascript\">const obj = {     foods: {         fruits: ['apple', 'orange'],     },     water: {         f: '',     },     tolupa: function(){         return this.name     }, }  const { foods } = obj  for(let k in obj){     console.log(k) \/\/ foods water tolupa } <\/code><\/pre>\n<p>  <\/p>\n<h3>9. \u041f\u0435\u0440\u0435\u0431\u043e\u0440 \u043a\u043b\u044e\u0447\u0435\u0439 \u043e\u0431\u044a\u0435\u043a\u0442\u0430 (Object.keys)<\/h3>\n<p>  \u0414\u0440\u0443\u0433\u043e\u0439 \u0441\u043f\u043e\u0441\u043e\u0431 \u043f\u0435\u0440\u0435\u0431\u0440\u0430\u0442\u044c \u043a\u043b\u044e\u0447\u0438 \u043e\u0431\u044a\u0435\u043a\u0442\u0430 \u0437\u0430\u043a\u043b\u044e\u0447\u0430\u0435\u0442\u0441\u044f \u0432 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0438 \u043c\u0435\u0442\u043e\u0434\u0430 Object.keys:  <\/p>\n<pre><code class=\"javascript\">const obj = {     foods: {         fruits: ['apple', 'orange'],     },     water: {         f: '',     },     tolupa: function(){         return this.name     }, }  const { foods } = obj  const keys = Object.keys(obj) console.log(keys) <\/code><\/pre>\n<p>  \u0420\u0430\u0437\u043d\u0438\u0446\u0430 \u0441\u043e\u0441\u0442\u043e\u0438\u0442 \u0432 \u0442\u043e\u043c, \u0447\u0442\u043e \u043c\u044b \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u043c \u043c\u0430\u0441\u0441\u0438\u0432 \u0441 \u043a\u043b\u044e\u0447\u0430\u043c\u0438, \u0441 \u043a\u043e\u0442\u043e\u0440\u044b\u043c \u043c\u043e\u0436\u043d\u043e \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0434\u0430\u043b\u044c\u0448\u0435.<\/p>\n<p>  \u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u044d\u0442\u043e \u043e\u0447\u0435\u043d\u044c \u0443\u0434\u043e\u0431\u043d\u043e, \u0435\u0441\u043b\u0438 \u043c\u044b \u0441\u043e\u0431\u0438\u0440\u0430\u0435\u043c\u0441\u044f \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0434\u0430\u043d\u043d\u044b\u0439 \u043c\u0430\u0441\u0441\u0438\u0432 \u0434\u043b\u044f \u0444\u0438\u043b\u044c\u0442\u0440\u0430\u0446\u0438\u0438:  <\/p>\n<pre><code class=\"javascript\">const people = {     bob: {         age: 15,         gender: 'male',     },     jessica: {         age: 24,         gender: 'female',     },     lucy: {         age: 11,         gender: 'female',     },     sally: {         age: 14,         gender: 'female',     }, }  const { males, females } = Object.keys(people).reduce(     (acc, name) =&gt; {         const person = people[name]         if(person.gender === 'male'){             acc.males.push(name)         } else{             acc.females.push(name)         }         return acc     },     { males: [], females: [] }, )  console.log(males) \/\/ ['bob'] console.log(females) \/\/ ['jessica', 'lucy', 'sally'] <\/code><\/pre>\n<p>  \u041d\u0430 \u044d\u0442\u043e\u043c \u0443 \u043c\u0435\u043d\u044f \u0432\u0441\u0435. \u041d\u0430\u0434\u0435\u044e\u0441\u044c, \u0441\u0442\u0430\u0442\u044c\u044f \u0431\u044b\u043b\u0430 \u0412\u0430\u043c \u043f\u043e\u043b\u0435\u0437\u043d\u043e\u0439. \u0414\u043e \u043d\u043e\u0432\u044b\u0445 \u0432\u0441\u0442\u0440\u0435\u0447!<\/div>\n<p> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/habr.com\/ru\/post\/485478\/\"> https:\/\/habr.com\/ru\/post\/485478\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"\n<div class=\"post__text post__text-html\" id=\"post-content-body\" data-io-article-url=\"https:\/\/habr.com\/ru\/post\/485478\/\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/df\/qu\/nw\/dfqunwkjczd_kruso0cb-xon_-c.jpeg\"><br \/>  \u0410\u0432\u0442\u043e\u0440 \u0444\u043e\u0442\u043e \u2014 <a href=\"https:\/\/unsplash.com\/@jesuskiteque\" rel=\"nofollow\">Jesus Kiteque<\/a>.<\/p>\n<p>  \u0414\u043e\u0431\u0440\u043e\u0433\u043e \u0432\u0440\u0435\u043c\u0435\u043d\u0438 \u0441\u0443\u0442\u043e\u043a, \u0434\u0440\u0443\u0437\u044c\u044f!<\/p>\n<p>  \u041f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u044f\u044e \u0412\u0430\u0448\u0435\u043c\u0443 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u044e \u043f\u0435\u0440\u0435\u0432\u043e\u0434 \u0441\u0442\u0430\u0442\u044c\u0438 jsmanifest <a href=\"https:\/\/medium.com\/better-programming\/9-ways-to-work-with-objects-in-javascript-in-2020-d772c29db429\" rel=\"nofollow\">\u00ab9 Ways to Work With Objects in JavaScript in 2020\u00bb<\/a>.<\/p>\n<h2>9 \u043f\u0440\u0438\u0435\u043c\u043e\u0432 \u0440\u0430\u0431\u043e\u0442\u044b \u0441 \u043e\u0431\u044a\u0435\u043a\u0442\u0430\u043c\u0438 \u0432 JavaScript \u0432 2020 \u0433\u043e\u0434\u0443<\/h2>\n<p>  JS, \u043a\u0430\u043a \u0438 \u043f\u0440\u043e\u0447\u0438\u0435 \u044f\u0437\u044b\u043a\u0438 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f, \u0438\u043c\u0435\u0435\u0442 \u043c\u043d\u043e\u0436\u0435\u0441\u0442\u0432\u043e \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u043e\u0432 \u0434\u043b\u044f \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f \u043a\u0430\u043a \u043f\u0440\u043e\u0441\u0442\u044b\u0445, \u0442\u0430\u043a \u0438 \u0441\u043b\u043e\u0436\u043d\u044b\u0445 \u0437\u0430\u0434\u0430\u0447. \u0414\u0430\u0432\u0430\u0439\u0442\u0435 \u043f\u043e\u0437\u043d\u0430\u043a\u043e\u043c\u0438\u043c\u0441\u044f \u0441 9 \u043f\u0440\u0438\u0435\u043c\u0430\u043c\u0438 \u0440\u0430\u0431\u043e\u0442\u044b \u0441 \u043e\u0431\u044a\u0435\u043a\u0442\u0430\u043c\u0438 \u0432 JS \u0432 2020 \u0433\u043e\u0434\u0443.<\/p>\n<p>  \u0417\u0430\u043c\u0435\u0447\u0430\u043d\u0438\u0435: \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0438\u0437 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u043d\u044b\u0445 \u043f\u0440\u0438\u0435\u043c\u043e\u0432 \u043f\u043e\u043a\u0430\u0436\u0443\u0442\u0441\u044f \u0412\u0430\u043c \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u044b\u043c\u0438, \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043e\u0447\u0435\u0432\u0438\u0434\u043d\u044b\u043c\u0438 (\u043f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u0445\u043e\u0440\u043e\u0448\u043e \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u044b), \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043f\u0440\u0438\u0432\u0435\u0434\u0435\u043d\u044b \u043f\u0440\u043e\u0441\u0442\u043e \u0434\u043b\u044f \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0438.<\/p>\n<p>  \u041a\u0430\u043a \u0431\u044b \u0442\u043e \u043d\u0438 \u0431\u044b\u043b\u043e, \u0435\u0441\u043b\u0438 \u0412\u0430\u043c \u043d\u0440\u0430\u0432\u0438\u0442\u0441\u044f \u043f\u0438\u0441\u0430\u0442\u044c \u043a\u043e\u0434 \u043d\u0430 JS, \u0412\u044b, \u043f\u043e\u0436\u0430\u043b\u0443\u0439, \u0441\u043e\u0433\u043b\u0430\u0441\u0438\u0442\u0435\u0441\u044c \u0441\u043e \u043c\u043d\u043e\u0439, \u0447\u0442\u043e \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0441 \u043e\u0431\u044a\u0435\u043a\u0442\u0430\u043c\u0438 \u043d\u0430\u043c\u043d\u043e\u0433\u043e \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u0435\u0439, \u0447\u0435\u043c \u0441 \u0434\u0440\u0443\u0433\u0438\u043c\u0438 \u0442\u0438\u043f\u0430\u043c\u0438.  <\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-297696","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/297696","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=297696"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/297696\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=297696"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=297696"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=297696"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}