Skip to content

Instantly share code, notes, and snippets.

View dayAlone's full-sized avatar

Andrey Kolmakov dayAlone

View GitHub Profile
@dayAlone
dayAlone / index.html
Last active November 11, 2020 05:29
JS Bin // source https://jsbin.com/xanuvon
<script src="https://cdn.jsdelivr.net/lodash/4/lodash.min.js"></script>
<script src="http://yui.yahooapis.com/3.10.0/build/yui/yui.js"></script>
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>JS Bin</title>
</head>
<body>
extends: 'stylelint-config-standard'
plugins:
- 'stylelint-order'
- 'stylelint-selector-bem-pattern'
rules:
unit-whitelist:
- px
- vh
- vw
- s
curl -X POST \
http://projects.aviasales.ru/kinder_email \
-H 'cache-control: no-cache' \
-H 'content-type: application/x-www-form-urlencoded' \
-d 'email=andrey.slider%40gmail.com&code=123'
{
"AES": "https://www.aviasales.ru/cities/aalesund-aes",
"JEG": "https://www.aviasales.ru/cities/aasiaat-jeg",
"ABD": "https://www.aviasales.ru/cities/abadan-abd",
"ABA": "https://www.aviasales.ru/cities/abakan-aba",
"YXX": "https://www.aviasales.ru/cities/abbotsford-yxx",
"ABR": "https://www.aviasales.ru/cities/aberdin-abr",
"ABZ": "https://www.aviasales.ru/cities/aberdin-abz",
"ABJ": "https://www.aviasales.ru/cities/abidzhan-abj",
"ABI": "https://www.aviasales.ru/cities/abilin-abi",
@dayAlone
dayAlone / 1
Last active April 17, 2017 12:09
1
<table bgcolor="#efe3c6" width="100%"; border="0"; cellpadding="0" cellspacing="0">
<tr>
<td>
<table bgcolor="#efe3c6" border="0" cellpadding="0" cellspacing="0" style="margin: 0 auto; padding: 0; font-family: Helvetica, Arial, sans-serif;" width="600">
<tr bgcolor="#efe3c6">
<td style="font-size: 14px; line-height: 24px;padding: 0px 82px 0px 82px;">
<table width="100%"; border="0"; cellpadding="0" cellspacing="0">
<tr>
<td style="padding: 30px 0px 0px 0px;">
<a href="https://aviasales.ru/?utm_source=autoreply&utm_medium=email&utm_campaign=as_sales_czechvacation" target="_blank"><img src="https://czechvacation.aviasales.ru/static/img/email-logo.png" alt=""></a>
@dayAlone
dayAlone / counters.html
Last active May 26, 2019 01:42
counters
<!-- Yandex.Metrika global start - do not remove!!! -->
<script type="text/javascript">
(function(d, w, c) {
(w[c] = w[c] || []).push(function() {
try {
w.yaCounter3791698 = w.yaCounter3791698 = new Ya.Metrika({
id: 3791698,
webvisor: true,
clickmap: true,
trackLinks: true,
# Your init script
#
# Atom will evaluate this file each time a new window is opened. It is run
# after packages are loaded/activated and after the previous editor state
# has been restored.
#
# An example hack to make opened Markdown files always be soft wrapped:
#
# path = require 'path'
#
@dayAlone
dayAlone / 1.js
Last active February 8, 2017 01:11
skyeng
['.b-vc-workplace-orderWord__holder'].map(selector =>
$(selector).toArray().map((el, key) => ({
right: $(selector + ':nth-child(' + (key + 1) + ') .b-vc-workplace-orderWord').toArray().map(el => Object.values(JSON.parse(el.getAttribute('drag-and-drop-order').match(/rightOrder:(.*) \}/)[1])).map(el => $$('[data-hash="' + el + '"] span')[1].innerText))[0],
answers: $(selector + ':nth-child(' + (key + 1) + ') .b-vc-workplace-orderWord__item span')
.toArray()
.map(el => el.innerText)
.filter(el => el.length > 0)
})))[0]
console.table($('#testform fieldset').map((key, el) => {
const parent = `#testform .testvoprosblock > div:nth-of-type(${key+1})`
const right = parseInt($(`${parent} input[value="2"]`)[0].getAttribute('valuez'), 10) + 1
const result = {
title: $(`${parent} .testvopros`)[0].innerHTML,
right: $(`${parent} .stylezed:nth-of-type(${right}) label`)[0].innerHTML,
}
return result
}).toArray())
//https://www.headspace.com/ajax?resource=/pack/all
const co = require('co')
const parallel = require('co-parallel')
const download = require('download')
const fetch = require('node-fetch')
const fs = require('fs')
const token = 'DJt2PcGT_vh7UAiX_1KeCxsPXhF7Aj79yc2fFdAoL1k'