Skip to content

Instantly share code, notes, and snippets.

Denis Lukov NeXTs

Block or report user

Report or block NeXTs

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@NeXTs
NeXTs / gist:487f3278ac48728d317a1557f6c63335
Created Mar 27, 2018
Thinnest JS RGB(a) string parser
View gist:487f3278ac48728d317a1557f6c63335
export const parseRGBa = palette => {
palette = palette.replace(/[^0-9.,]/g, '').split(',').map(Number)
if(palette.length == 3) palette.push(1) // add alpha if missed
return palette
}
@NeXTs
NeXTs / gist:a1f9549a1768774eb12e
Created Dec 15, 2015
Devtools separate window
View gist:a1f9549a1768774eb12e
import React from 'react';
import { render } from 'react-dom';
import { DevTools, DebugPanel, LogMonitor } from 'redux-devtools/lib/react';
/*
* Puts Redux DevTools into a separate window.
* Based on https://gist.github.com/tlrobinson/1e63d15d3e5f33410ef7#gistcomment-1560218
*/
export default function createDevToolsWindow(store) {
// Give it a name so it reuses the same window
@NeXTs
NeXTs / goto-sublime
Created Oct 29, 2015 — forked from kendellfab/goto-sublime
Add mouse click `goto definition` in sublime text 3.
View goto-sublime
Linux - create "Default (Linux).sublime-mousemap" in ~/.config/sublime-text-3/Packages/User
Mac - create "Default (OSX).sublime-mousemap" in ~/Library/Application Support/Sublime Text 3/Packages/User
Win - create "Default (Windows).sublime-mousemap" in %appdata%\Sublime Text 3\Packages\User
[
{
"button": "button1",
"count": 1,
"modifiers": ["ctrl"],
"press_command": "drag_select",
View Get human address from Yandex Maps v2.0 geoObject "AddressDetails"
function getHumanAddress(geoObject){
var declaration = {
'CountryName': 'country',
'AdministrativeAreaName': 'area',
'SubAdministrativeAreaName': 'subarea',
'LocalityName': 'city',
'DependentLocalityName': 'subcity',
'ThoroughfareName': 'street',
'PremiseNumber': 'house'
},
You can’t perform that action at this time.