This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
conf: Falsy Values 2015 | |
author: Kornel Lesinski | |
theme: And .then() what? Promise programming patterns | |
link: https://www.youtube.com/watch?v=KrhQE8K2I7Q | |
*/ | |
// 1 waterfall. Использование результатов предыдущих промисов | |
doFirst() | |
.then(firstResult => { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
How to disable auto-save: | |
Go to File > Settings (Ctrl+Alt+S). | |
Go to Appearance & Behavior > System Settings. | |
Make sure the two are unchecked: | |
Save files on frame deactivation | |
Save files automatically if application is idle for x sec. | |
Go to Editor > General > Editor Tabs | |
Put a checkmark on "Mark modified files with asterisk" | |
(Optional but recommended) Under "Tab Closing Policy", select "Close non-modified files first". You may also want to increase the number of allowed tabs. | |
Click Apply > OK. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$(".data").mask("AB/CD/0000", { | |
translation:{ | |
A: {pattern: /[0-3]/}, | |
B: {pattern: /[0-9]/}, | |
C: {pattern: /[0-1]/}, | |
D: {pattern: /[0-9]/}, | |
}, | |
onKeyPress: function(a, b, c, d) { | |
if (!a) return; | |
var m = a.match(/(\d{2})/g); |