{"id":184168,"date":"2013-06-21T15:55:03","date_gmt":"2013-06-21T11:55:03","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=184168"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=184168","title":{"rendered":"<span class=\"post_title\">Angular.js + Knockout.js<\/span>"},"content":{"rendered":"<div class=\"content html_format\">   \t\u041d\u0435\u0434\u0430\u0432\u043d\u043e \u044f \u043f\u0435\u0440\u0435\u0448\u0435\u043b \u0441 knockout.js \u043d\u0430 angular.js, \u043e\u0431\u0430 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u0430 \u043c\u043d\u0435 \u043d\u0440\u0430\u0432\u044f\u0442\u0441\u044f, \u043d\u043e \u0432 \u043a\u0430\u0436\u0434\u043e\u043c \u0438\u0437 \u043d\u0438\u0445 \u0435\u0441\u0442\u044c \u0441\u0432\u043e\u0438 \u043f\u0440\u0435\u0438\u043c\u0443\u0449\u0435\u0441\u0442\u0432\u0430 \u043f\u0435\u0440\u0435\u0434 \u00ab\u043a\u043e\u043d\u043a\u0443\u0440\u0435\u043d\u0442\u043e\u043c\u00bb.<br \/>  \u0418 \u0442\u0443\u0442 \u0432\u044b\u043f\u0430\u043b \u0441\u043a\u0443\u0447\u043d\u044b\u0439 \u0432\u0435\u0447\u0435\u0440, \u0440\u0435\u0448\u0438\u043b \u044f, just for fun, \u0441\u043b\u0435\u043f\u0438\u0442\u044c \u0441\u0432\u043e\u0439 MV* \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442.<\/p>\n<p>  \u041c\u043d\u0435 \u043d\u0435 \u043e\u0447\u0435\u043d\u044c \u043d\u0440\u0430\u0432\u044f\u0442\u0441\u044f \u0440\u0430\u0437\u0443\u0445\u0430\u0431\u0438\u0441\u0442\u044b\u0435 \u0444\u0440\u0435\u0439\u043c\u0432\u043e\u0440\u043a\u0438, \u044f \u043e\u0442\u0434\u0430\u044e \u043f\u0440\u0435\u0434\u043f\u043e\u0447\u0442\u0435\u043d\u0438\u0435 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0430\u043c, \u0438 \u043e\u0442 angular \u043c\u043d\u0435 \u0432 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u043c \u043d\u0443\u0436\u043d\u043e \u0431\u044b\u043b\u043e 2 \u0432\u0435\u0449\u0438: <b>scope<\/b> \u2014 \u0434\u0430\u043d\u043d\u044b\u0435 \u0438 \u0438\u0445 \u043c\u043e\u043d\u0438\u0442\u043e\u0440\u0438\u043d\u0433, <b>applyBindings<\/b> \u2014 \u043f\u0440\u0438\u0432\u044f\u0437\u0430\u0442\u044c \u044d\u0442\u043e\u0442 scope \u043a DOM.<br \/>  <a name=\"habracut\"><\/a><br \/>  \u0421 \u044d\u0442\u043e\u0433\u043e \u044f \u0438 \u043d\u0430\u0447\u0430\u043b \u0441\u0432\u043e\u0439 \u0432\u0435\u043b\u043e\u0441\u0438\u043f\u0435\u0434, \u0432 \u0438\u0442\u043e\u0433\u0435 \u0443 \u043c\u0435\u043d\u044f \u0435\u0441\u0442\u044c:  <\/p>\n<blockquote><p>scope&nbsp;<font color=\"#339933\">=<\/font>&nbsp;alite.<font color=\"#660066\">Scope<\/font><font color=\"#009900\">(<\/font><font color=\"#009900\">)<\/font><font color=\"#339933\">;<\/font>&nbsp;<font color=\"#339933\">&#8212;<\/font>&nbsp;\u0441\u043e\u0437\u0434\u0430\u0442\u044c&nbsp;scope<br \/>  alite.<font color=\"#660066\">applyBindings<\/font><font color=\"#009900\">(<\/font>scope<font color=\"#339933\">,<\/font>&nbsp;dom<font color=\"#009900\">)<\/font><font color=\"#339933\">;<\/font>&nbsp;<font color=\"#339933\">&#8212;<\/font>&nbsp;\u043f\u0440\u0438\u0432\u044f\u0437\u0430\u0442\u044c&nbsp;\u043a&nbsp;DOM<\/p><\/blockquote>\n<p>  \u0414\u043e\u0431\u0430\u0432\u0438\u043c \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u0443\u044e:  <\/p>\n<blockquote><p>scope.<font color=\"#660066\">title<\/font>&nbsp;<font color=\"#339933\">=<\/font>&nbsp;<font color=\"#3366CC\">&#8216;hello&#8217;<\/font><font color=\"#339933\">;<\/font><\/p><\/blockquote>\n<p>  \u0418 \u0441\u0434\u0435\u043b\u0430\u0435\u043c \u00abbind\u00bb \u0432 DOM:  <\/p>\n<blockquote><p>&nbsp;&nbsp;&nbsp;&nbsp;<font color=\"#009900\">&lt;<font color=\"#000000\">h1<\/font>&nbsp;data-bind<font color=\"#66cc66\">=<\/font><font color=\"#ff0000\">&quot;text:&nbsp;title&quot;<\/font>&gt;&lt;<font color=\"#66cc66\">\/<\/font><font color=\"#000000\">h1<\/font>&gt;<\/font><br \/>  &nbsp;&nbsp;&nbsp;&nbsp;<font color=\"#009900\">&lt;<font color=\"#000000\">input<\/font>&nbsp;<font color=\"#000066\">type<\/font><font color=\"#66cc66\">=<\/font><font color=\"#ff0000\">&quot;text&quot;<\/font>&nbsp;data-bind<font color=\"#66cc66\">=<\/font><font color=\"#ff0000\">&quot;value:&nbsp;title&quot;<\/font>&nbsp;<font color=\"#66cc66\">\/<\/font>&gt;<\/font><br \/>  &nbsp;<\/p><\/blockquote>\n<p>\u041f\u0440\u0438\u043c\u0435\u0440:<br \/>  <a href=\"http:\/\/plnkr.co\/edit\/nvDY1k?p=preview\">plnkr.co\/edit\/nvDY1k?p=preview<\/a><\/p>\n<p>  \u041f\u0440\u0438\u043c\u0435\u0440 ToDo:<br \/>  <a href=\"http:\/\/plnkr.co\/edit\/FAcLlC?p=preview\">plnkr.co\/edit\/FAcLlC?p=preview<\/a><\/p>\n<p>  \u0414\u0438\u0440\u0435\u043a\u0442\u0438\u0432\u044b \u2014 \u043e\u0431\u044b\u0447\u043d\u044b\u0435 \u0444-\u0438\u0438 \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0432\u044b\u0437\u044b\u0432\u0430\u044e\u0442\u0441\u044f \u043a\u043e\u0433\u0434\u0430 applyBindings \u0434\u043e\u0445\u043e\u0434\u0438\u0442 \u0434\u043e data-bind, \u0441\u043a\u043b\u0430\u0434\u044b\u0432\u0430\u0435\u043c \u0438\u0445 \u0432 alite.directives:  <\/p>\n<blockquote><p>alite.<font color=\"#660066\">directives<\/font>.<font color=\"#660066\">text<\/font>&nbsp;<font color=\"#339933\">=<\/font>&nbsp;<font color=\"#003366\">function<\/font><font color=\"#009900\">(<\/font>element<font color=\"#339933\">,<\/font>&nbsp;attrs<font color=\"#339933\">,<\/font>&nbsp;scope<font color=\"#009900\">)<\/font>&nbsp;<font color=\"#009900\">{<\/font><br \/>  &nbsp;&nbsp;&nbsp;&nbsp;<font color=\"#003366\">var<\/font>&nbsp;attr&nbsp;<font color=\"#339933\">=<\/font>&nbsp;attrs.<font color=\"#660066\">text<\/font><font color=\"#339933\">;<\/font>&nbsp;&nbsp;<font color=\"#006600\">\/\/&nbsp;\u0418\u043c\u044f&nbsp;\u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0430<\/font><br \/>  &nbsp;&nbsp;&nbsp;&nbsp;scope.$watch<font color=\"#009900\">(<\/font>attr<font color=\"#339933\">,<\/font>&nbsp;<font color=\"#003366\">function<\/font><font color=\"#009900\">(<\/font>value<font color=\"#009900\">)<\/font>&nbsp;<font color=\"#009900\">{<\/font>&nbsp;&nbsp;<font color=\"#006600\">\/\/&nbsp;\u041f\u043e\u0434\u043f\u0438\u0441\u044b\u0432\u0430\u0435\u043c\u0441\u044f&nbsp;\u043d\u0430&nbsp;\u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u044f<\/font><br \/>  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;element.<font color=\"#660066\">text<\/font><font color=\"#009900\">(<\/font>value<font color=\"#009900\">)<\/font><font color=\"#339933\">;<\/font>&nbsp;&nbsp;<font color=\"#006600\">\/\/&nbsp;\u0412\u044b\u0432\u043e\u0434\u0438\u043c&nbsp;\u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435&nbsp;(\u0447\u0435\u0440\u0435\u0437&nbsp;jQuery)<\/font><br \/>  &nbsp;&nbsp;&nbsp;&nbsp;<font color=\"#009900\">}<\/font><font color=\"#009900\">)<\/font><br \/>  &nbsp;<br \/>  &nbsp;&nbsp;&nbsp;&nbsp;<font color=\"#003366\">var<\/font>&nbsp;value&nbsp;<font color=\"#339933\">=<\/font>&nbsp;scope.$eval<font color=\"#009900\">(<\/font>attr<font color=\"#009900\">)<\/font><font color=\"#339933\">;<\/font>&nbsp;<font color=\"#006600\">\/\/&nbsp;\u041f\u043e\u043b\u0443\u0447\u0438\u0442\u044c&nbsp;\u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435<\/font><br \/>  &nbsp;&nbsp;&nbsp;&nbsp;element.<font color=\"#660066\">text<\/font><font color=\"#009900\">(<\/font>value<font color=\"#009900\">)<\/font><font color=\"#339933\">;<\/font><br \/>  <font color=\"#009900\">}<\/font><font color=\"#339933\">;<\/font><\/p><\/blockquote>\n<p>  <b>\u041d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0444\u0430\u043a\u0442\u043e\u0440\u044b \u0432 \u0437\u0430\u0449\u0438\u0442\u0443 \u00ab\u0432\u0435\u043b\u043e\u0441\u0438\u043f\u0435\u0434\u0430\u00bb:<\/b>  <\/p>\n<ul>\n<li>\u0412 angular \u043c\u043d\u0435 \u043d\u0435 \u0432\u0441\u0435\u0433\u0434\u0430 \u043d\u0440\u0430\u0432\u0438\u0442\u0441\u044f \u00ab\u0432\u043e\u0437\u043d\u044f\u00bb \u0441 \u043c\u043e\u0434\u0443\u043b\u044f\u043c\u0438. (\u0441\u0434\u0435\u043b\u0430\u043b \u044d\u0442\u043e \u043f\u043e\u0434\u043e\u0431\u043d\u043e \u043a\u0430\u043a \u0432 knockout.js)<\/li>\n<li>\u041f\u043e\u0447\u0435\u043c\u0443 data-bind? \u0427\u0442\u043e-\u0431\u044b \u0432\u044b\u0441\u043a\u0430\u043a\u0438\u0432\u0430\u043b\u0430 \u043e\u0448\u0438\u0431\u043a\u0430 \u0435\u0441\u043b\u0438 \u0434\u0438\u0440\u0435\u043a\u0442\u0438\u0432\u044b \u043d\u0435\u0442, \u0445\u043e\u0442\u044f \u043c\u043e\u0436\u043d\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u043a\u0430\u043a \u0443\u0433\u043e\u0434\u043d\u043e. (\u043f\u043e\u0434\u043e\u0431\u043d\u043e \u043a\u0430\u043a \u0432 knockout.js)<\/li>\n<li>\u041e jQuery: Angular \u0438 Knockout \u0440\u0430\u0431\u043e\u0442\u0430\u044e\u0442 \u0431\u0435\u0437 jQuery \u0438 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u044e\u0442 \u0440\u0430\u0437\u043d\u044b\u0435 \u0432\u0438\u0434\u044b \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u043e\u0432, \u0442.\u0435. \u0443 \u043d\u0438\u0445 \u0437\u0430\u043b\u043e\u0436\u0435\u043d\u0430 \u044d\u0442\u0430 \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u043e\u0441\u0442\u044c \u0432\u043d\u0443\u0442\u0440\u0438. \u041d\u043e \u0437\u0430\u0447\u0435\u043c, \u0435\u0441\u043b\u0438 \u043c\u043e\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c jQuery, \u0432\u0441\u0435 \u0440\u0430\u0432\u043d\u043e \u0435\u0433\u043e \u043f\u0440\u0438\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0430\u0442\u044c (\u0447\u0443\u0442\u044c \u043b\u0438 \u043d\u0435) \u0432 \u043a\u0430\u0436\u0434\u044b\u0439 \u043f\u0440\u043e\u0435\u043a\u0442, \u0440\u0430\u0434\u0438 timepicker, select2 \u0438 \u043f\u0440.<br \/>  (\u0442\u043e\u0442 \u0436\u0435 angular.ui \u0442\u0440\u0435\u0431\u0443\u0434\u0435\u0442 jquery). \u0425\u043e\u0442\u044f \u043c\u043e\u0436\u0435\u0442 \u043e\u043d \u043d\u0435 \u043d\u0443\u0436\u0435\u043d \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u0434\u043b\u044f \u0441\u0432\u044f\u0437\u043e\u043a Knockout.js + kendo-ui.<\/li>\n<li>\u00ab\u0414\u043b\u044f angular.js \u0435\u0441\u0442\u044c \u043c\u043d\u043e\u0433\u043e \u0433\u043e\u0442\u043e\u0432\u044b\u0445 \u0434\u0438\u0440\u0435\u043a\u0442\u0438\u0432!\u00bb. \u041d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0438\u0445 \u043f\u0440\u043e\u0435\u043a\u0442\u043e\u0432 \u0441 angular.js \u043f\u043e\u043a\u0430\u0437\u0430\u043b\u0438 \u0447\u0442\u043e \u043c\u043d\u043e\u0433\u0438\u0435 \u0433\u043e\u0442\u043e\u0432\u044b\u0435 \u0434\u0438\u0440\u0435\u043a\u0442\u0438\u0432\u044b \u043b\u0438\u0431\u043e \u043d\u0435 \u043f\u043e\u0434\u0445\u043e\u0434\u044f\u0442 \u043b\u0438\u0431\u043e \u0438\u0445 \u043d\u0435\u0442. \u0412 \u0438\u0442\u043e\u0433\u0435 \u0432\u0441\u0435 \u0440\u0430\u0432\u043d\u043e \u043f\u0440\u0438\u0448\u043b\u043e\u0441\u044c \u0438\u0445 \u0434\u0435\u043b\u0430\u0442\u044c \u0441\u0430\u043c\u043e\u043c\u0443. \u041f\u043e\u044d\u0442\u043e\u043c\u0443 \u043f\u043e\u0434\u043e\u0431\u043d\u044b\u0439 \u0432\u0435\u043b\u043e\u0441\u0438\u043f\u0435\u0434 (\u043d\u043e product \u0432\u0435\u0440\u0441\u0438\u0438) \u0431\u0435\u0437 \u0433\u043e\u0442\u043e\u0432\u044b\u0445 \u0434\u0438\u0440\u0435\u043a\u0442\u0438\u0432 \u0431\u044b\u043b \u0431\u044b \u043d\u0435 \u0445\u0443\u0436\u0435 \u0447\u0435\u043c angular.js<\/li>\n<\/ul>\n<p>  \u0414\u0438\u0440\u0435\u043a\u0442\u0438\u0432\u044b, \u0445\u043e\u0442\u044f \u0432 knockoute \u043c\u043e\u0436\u043d\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0430\u043d\u0430\u043b\u043e\u0433\u0438\u0447\u043d\u044b\u0435, \u0432\u0441\u0435 \u0436\u0435 \u0438\u0437 \u043a\u043e\u0440\u043e\u0431\u043a\u0438 \u043e\u043d\u0438 \u0434\u0440\u0443\u0433\u0438\u0435:<br \/>  bind click: data-bind=\u00abclick: on_click()\u00bb \u2014 \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u043c \u0442\u043e \u0447\u0442\u043e \u043d\u0443\u0436\u043d\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c, \u0432\u043c\u0435\u0441\u0442\u043e \u0443\u043a\u0430\u0437\u0430\u043d\u0438\u044f \u0444-\u0438\u0438 \u043a\u0430\u043a \u0432 knockout (\u043f\u043e\u0434\u043e\u0431\u043d\u043e \u043a\u0430\u043a \u0432 angular.js)<br \/>  bind repeat:  \u2014 \u043a\u0440\u0443\u0442\u0438\u043c \u0441\u0430\u043c \u044d\u043b\u0435\u043c\u0435\u043d\u0442, \u0430 \u043d\u0435 \u0435\u0433\u043e \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u043c\u043e\u0435 (\u043f\u043e\u0434\u043e\u0431\u043d\u043e \u043a\u0430\u043a \u0432 angular.js)<\/p>\n<p>  \u00ab\u042f\u0434\u0440\u043e\u00bb (\u043f\u043e\u043a\u0430) \u0441\u043e\u0441\u0442\u043e\u0438\u0442 \u0432\u0441\u0435\u0433\u043e \u043b\u0438\u0448\u044c \u0438\u0437 \u043f\u0440\u0438\u043c\u0435\u0440\u043d\u043e 200 \u0441\u0442\u0440\u043e\u043a, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0435\u0433\u043e \u043c\u043e\u0436\u043d\u043e \u0431\u0443\u0434\u0435\u0442 \u043b\u0435\u0433\u043a\u043e \u043f\u0435\u0440\u0435\u043f\u0438\u043b\u0438\u0442\u044c \u043f\u043e\u0434 \u0441\u0435\u0431\u044f.<\/p>\n<p>  PS: \u042d\u0442\u043e \u0432\u0441\u0435\u0433\u043e \u043b\u0438\u0448\u044c \u043f\u0440\u043e\u0442\u043e\u0442\u0438\u043f \u0432\u0435\u043b\u043e\u0441\u0438\u043f\u0435\u0434\u0430, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0432 \u043d\u0435\u043c \u0447\u0442\u043e-\u0442\u043e \u043d\u0435 \u0431\u0443\u0434\u0435\u0442 \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c.  \t\t\t\t<\/p>\n<div class=\"polling\">\n<form action=\"\/json\/polling\/\" class=\"poll\" method=\"post\">\n<div class=\"poll_title\">\u0421\u0442\u043e\u0438\u0442 \u043b\u0438 \u0440\u0430\u0437\u0432\u0438\u0432\u0430\u0442\u044c?<\/div>\n<p>  \t\t<input type=\"hidden\" name=\"post_id\" value=\"184168\"\/> \t\t<input type=\"hidden\" name=\"polling_question_id\" value=\"8250\"\/>  \t\t<\/p>\n<table class=\"answer\">\n<tr>\n<td class=\"input\"> \t\t\t\t\t<input type=\"radio\" id=\"vv42466\" \t\t\t\t\t\tclass=\"radio js-field-data\" \t\t\t\t\t\tname=\"variant[]\" \t\t\t\t\t\tvalue=\"42466\" \/> \t\t\t\t<\/td>\n<td class=\"label\"> \t\t\t\t\t<label for=\"vv42466\">\u041d\u0435\u0442, \u043f\u043e\u0445\u043e\u0440\u043e\u043d\u0438\u0442\u044c.<\/label> \t\t\t\t<\/td>\n<\/tr>\n<tr>\n<td class=\"input\"> \t\t\t\t\t<input type=\"radio\" id=\"vv42468\" \t\t\t\t\t\tclass=\"radio js-field-data\" \t\t\t\t\t\tname=\"variant[]\" \t\t\t\t\t\tvalue=\"42468\" \/> \t\t\t\t<\/td>\n<td class=\"label\"> \t\t\t\t\t<label for=\"vv42468\">\u0414\u0430.<\/label> \t\t\t\t<\/td>\n<\/tr>\n<tr>\n<td class=\"input\"> \t\t\t\t\t<input type=\"radio\" id=\"vv42470\" \t\t\t\t\t\tclass=\"radio js-field-data\" \t\t\t\t\t\tname=\"variant[]\" \t\t\t\t\t\tvalue=\"42470\" \/> \t\t\t\t<\/td>\n<td class=\"label\"> \t\t\t\t\t<label for=\"vv42470\">\u044f \u041d\u041b\u041e<\/label> \t\t\t\t<\/td>\n<\/tr>\n<\/table>\n<p class=\"for_users_only_msg\">\u0422\u043e\u043b\u044c\u043a\u043e \u0437\u0430\u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0435 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0438 \u043c\u043e\u0433\u0443\u0442 \u0443\u0447\u0430\u0441\u0442\u0432\u043e\u0432\u0430\u0442\u044c \u0432 \u043e\u043f\u0440\u043e\u0441\u0435. <a href=\"\/login\/\">\u0412\u043e\u0439\u0434\u0438\u0442\u0435<\/a>, \u043f\u043e\u0436\u0430\u043b\u0443\u0439\u0441\u0442\u0430.<\/p>\n<p class=\"total\">\u041d\u0438\u043a\u0442\u043e \u0435\u0449\u0451 \u043d\u0435 \u0433\u043e\u043b\u043e\u0441\u043e\u0432\u0430\u043b. \u0412\u043e\u0437\u0434\u0435\u0440\u0436\u0430\u0432\u0448\u0438\u0445\u0441\u044f \u043d\u0435\u0442.<\/p>\n<\/p><\/form>\n<\/p><\/div>\n<div class=\"clear\"><\/div>\n<\/p><\/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=\"http:\/\/habrahabr.ru\/post\/184168\/\"> http:\/\/habrahabr.ru\/post\/184168\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<div class=\"content html_format\">   \t\u041d\u0435\u0434\u0430\u0432\u043d\u043e \u044f \u043f\u0435\u0440\u0435\u0448\u0435\u043b \u0441 knockout.js \u043d\u0430 angular.js, \u043e\u0431\u0430 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u0430 \u043c\u043d\u0435 \u043d\u0440\u0430\u0432\u044f\u0442\u0441\u044f, \u043d\u043e \u0432 \u043a\u0430\u0436\u0434\u043e\u043c \u0438\u0437 \u043d\u0438\u0445 \u0435\u0441\u0442\u044c \u0441\u0432\u043e\u0438 \u043f\u0440\u0435\u0438\u043c\u0443\u0449\u0435\u0441\u0442\u0432\u0430 \u043f\u0435\u0440\u0435\u0434 \u00ab\u043a\u043e\u043d\u043a\u0443\u0440\u0435\u043d\u0442\u043e\u043c\u00bb.<br \/>  \u0418 \u0442\u0443\u0442 \u0432\u044b\u043f\u0430\u043b \u0441\u043a\u0443\u0447\u043d\u044b\u0439 \u0432\u0435\u0447\u0435\u0440, \u0440\u0435\u0448\u0438\u043b \u044f, just for fun, \u0441\u043b\u0435\u043f\u0438\u0442\u044c \u0441\u0432\u043e\u0439 MV* \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442.<\/p>\n<p>  \u041c\u043d\u0435 \u043d\u0435 \u043e\u0447\u0435\u043d\u044c \u043d\u0440\u0430\u0432\u044f\u0442\u0441\u044f \u0440\u0430\u0437\u0443\u0445\u0430\u0431\u0438\u0441\u0442\u044b\u0435 \u0444\u0440\u0435\u0439\u043c\u0432\u043e\u0440\u043a\u0438, \u044f \u043e\u0442\u0434\u0430\u044e \u043f\u0440\u0435\u0434\u043f\u043e\u0447\u0442\u0435\u043d\u0438\u0435 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0430\u043c, \u0438 \u043e\u0442 angular \u043c\u043d\u0435 \u0432 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u043c \u043d\u0443\u0436\u043d\u043e \u0431\u044b\u043b\u043e 2 \u0432\u0435\u0449\u0438: <b>scope<\/b> \u2014 \u0434\u0430\u043d\u043d\u044b\u0435 \u0438 \u0438\u0445 \u043c\u043e\u043d\u0438\u0442\u043e\u0440\u0438\u043d\u0433, <b>applyBindings<\/b> \u2014 \u043f\u0440\u0438\u0432\u044f\u0437\u0430\u0442\u044c \u044d\u0442\u043e\u0442 scope \u043a DOM.  <\/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-184168","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/184168","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=184168"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/184168\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=184168"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=184168"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=184168"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}