In this example we are integrating a 3rd party jQuery plugin (select2) by wrapping it inside a custom component.
Resourses
- [email protected]
- select2.min.css
- [email protected]
- vue.js
In this example we are integrating a 3rd party jQuery plugin (select2) by wrapping it inside a custom component.
Resourses
| .catch((errorResp) => { | |
| if (!errorResp.data || !errorResp.data.error || !errorResp.data.error.message) { | |
| Utils.alert.error('Возникла ошибка. Повторите попытку.'); | |
| return; | |
| } | |
| Utils.alert | |
| .error(errorResp.data.error.message); | |
| }) |
| //1. Строка, состоящая из одного символа или вообще без символов | |
| //2. Любая другая символьная строка является палиндромом, если первый и последний ее символы | |
| //одинаковы , а остальная часть строки, кроме этих символов, оказывается палиндромом. | |
| function isPalindrome(text) { | |
| if (text.length <= 1) return true; | |
| if (text.charAt(0) != text.charAt(text.length - 1)) return false; | |
| return isPalindrome(text.substr(1, text.length - 2)); | |
| } | |
| test( "isPalindrome test", function() { |
| Array.prototype.each = function(callback){ | |
| for(var i = 0; i < this.length; i++) { | |
| callback.call(this[i]) | |
| } | |
| }; | |
| // ["sdf", 423].each(function(){alert(this)}); | |
| var MyArray = function() { | |
| return( this ); | |
| }; |
| <?xml version="1.0" encoding="UTF-8" ?> | |
| <xsl:stylesheet version="1.0" | |
| xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> | |
| <xsl:output method="html" | |
| encoding="UTF-8" | |
| doctype-public=""/> | |
| <xsl:strip-space elements="*"/> | |
| <!-- Обработка корня документа --> |
| http://jzaefferer.github.io/undo/demos/contenteditable.html |
| http://jsbin.com/EmuVifAS/1/watch?js,console,output |
| *205# |
| function Parent(name) { | |
| this.name = name || 'Adam'; | |
| } | |
| Parent.prototype.say = function() { | |
| return this.name; | |
| }; | |
| function Child(name) { | |
| Parent.apply(this, arguments); |
| function Article() { | |
| this.tags = ['js', 'css']; | |
| } | |
| Article.prototype.printTagsList = function() { | |
| console.log( this.tags.join(', ')); | |
| }; | |
| var article = new Article(); |