Skip to content

Instantly share code, notes, and snippets.

View NeXTs's full-sized avatar

Denis NeXTs

  • Odessa, Ukraine
View GitHub Profile
function getHumanAddress(geoObject){
var declaration = {
'CountryName': 'country',
'AdministrativeAreaName': 'area',
'SubAdministrativeAreaName': 'subarea',
'LocalityName': 'city',
'DependentLocalityName': 'subcity',
'ThoroughfareName': 'street',
'PremiseNumber': 'house'
},
@NeXTs
NeXTs / goto-sublime
Created October 29, 2015 14:18 — forked from kendellfab/goto-sublime
Add mouse click `goto definition` in sublime text 3.
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",
@NeXTs
NeXTs / gist:a1f9549a1768774eb12e
Created December 15, 2015 21:47
Devtools separate window
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 / gist:487f3278ac48728d317a1557f6c63335
Created March 27, 2018 10:52
Thinnest JS RGB(a) string parser
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
}