~/Library/Preferences/PhpStorm*/phpstorm.vmoptions
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
// Works out the width of elements based | |
// on total number of columns and width | |
// number of columns being displayed. | |
// Values for @grid would be 12, 16 or 24 | |
.grid-inline-block(@grid: 12, @margin: 0, @width: 100%) { | |
@actions: column, prefix, suffix, pull, push; | |
.grid-action(block){ | |
display: inline-block; | |
vertical-align: top; |
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
<?php | |
$url = 'http://www.cbr.ru/scripts/XML_daily.asp'; | |
$ch = curl_init( $url ); | |
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, "GET"); | |
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); | |
$result = curl_exec( $ch ); | |
curl_close($ch); | |
$xml = new SimpleXMLElement($result); |
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
t=this.open(); | |
t.addEventListener('DOMContentloaded',(e)=>{ | |
console.log(this, e); | |
e.target.close(); | |
}); | |
t.dispatchEvent(new CustomEvent('DOMContentloaded')); |
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
<body><script>eval('!function(t,i,s,h,n,o,e,a,r){function f(){var t=this.contro\ | |
ls,i=this.id=this.id||(1e17*Math.random()).toString(32);this.I=function(s){for(\ | |
var h in t)s.which===t[h]&&dispatchEvent(new Event(h+i))},this.A()}function p(t\ | |
){return function(){var i,s=this.controls,h=this.id;for(i in s)t(i+h,this[i].bi\ | |
nd(this));t(\"keydown\",this.I)}}function l(i){this.h=this.g=0,s(this,i),this.x\ | |
=this.g,this.y=this.h,this.path=new t(this.d),f.apply(this,arguments),this.move\ | |
To()}function u(){l.apply(this,arguments)}function d(){clearInterval(this.m),th\ | |
is.i()}function y(){l.apply(this,arguments)}function v(){l.apply(this,arguments\ | |
),this.o()}function b(t){var c=i.body.appendChild(i.createElement(\"canvas\"));\ | |
s(this,t),c.height=1.5*(c.width=170),this.a=[],this.b=c.getContext(\"2d\"),f.ap\ |
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
var a = [5,3,7,1,10,-1]; | |
quicksort.call(a); | |
console.log(a); // -1, 1, 3, 5, 7, 10 |
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
var d = 'M100,35c0-13-11-25-25-25s-25,12-25,18c0-5-11-18-25-18s-25,11-25,25c0,20,36,49,50,62,14-14,50-43,50-62z'; | |
var pd = new PathData(); | |
pd.fromString(d); | |
pd.scale(2) | |
pd.toString() |
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
e=eval( | |
s="((t,c,d,...x)=>([\ | |
...x.map(x=>new x[c])\ | |
,t,c,d,s\ | |
],'No code no bugs'))(\ | |
this,\ | |
'constructor',\ | |
'document',\ | |
!1,\ | |
0,\ |
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
;window.APIService = (function(_){ | |
function ajax(headers, url, method, data, onsuccess, onerror) { | |
var request = new XMLHttpRequest(); | |
request.open(method, url, true); | |
_.forEach(headers, function(v, k){ | |
request.setRequestHeader(k, v); | |
}); | |
request.onsuccess = onsuccess || function(){}; | |
request.onerror = onerror || function(){}; | |
request.onload = function() { |
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
DIR_STATIC = app_static | |
DIR_TDP = tdp.ru/v02 | |
DIR_CART = cart-module | |
# Help | |
# https://gist.github.com/prwhite/8168133 | |
help: ## Show this help. | |
@echo "\ | |
Release workflow\n\ | |
1. Build in local branch or milestone\n\ |