Skip to content

Instantly share code, notes, and snippets.

View danasilver's full-sized avatar

Dana Silver danasilver

View GitHub Profile
@danasilver
danasilver / citystategeo.js
Created July 17, 2013 20:11
Get only city and state from Google Maps API Reverse Geocoder
if (window.navigator.geolocation) {
navigator.geolocation.getCurrentPosition(function (position) {
var lat = position.coords.latitude,
lng = position.coords.longitude,
latlng = new google.maps.LatLng(lat, lng),
geocoder = new google.maps.Geocoder();
geocoder.geocode({'latLng': latlng}, function(results, status) {
if (status == google.maps.GeocoderStatus.OK) {
if (results[1]) {
for (var i = 0; i < results.length; i++) {
@danasilver
danasilver / .block
Created April 7, 2016 04:12
Snap to Grid
license: MIT
@danasilver
danasilver / README.md
Last active November 6, 2017 12:48
Jekyll Pygments/Redcarpet Global Configs

Jekyll Pygments/Redcarpet Global Configs

A Jekyll plugin that enables global configuration options for Pygments.

  • Add pygments_global_config.rb to my-jekyll-project/_plugins/.

  • Add Pygments options to _config.yml

markdown: redcarpet
@danasilver
danasilver / .block
Last active December 18, 2016 02:14
Heady Topper Locations
license: MIT
@danasilver
danasilver / Preferences.sublime-settings
Created November 26, 2016 17:06
Sublime Preferences
{
"color_scheme": "Packages/User/SublimeLinter/Color Brewer (SL).tmTheme",
"drawWhiteSpace": true,
"draw_white_space": "none",
"ensure_newline_at_eof_on_save": true,
"font_face": "Inconsolata",
"font_size": 15,
"ignored_packages":
[
"HTML-CSS-JS Prettify",
@danasilver
danasilver / README.md
Created August 4, 2016 05:57
Computed Text Placement

The bar's text is positioned using its computed size to determine if it fits in the bar. Slide the input to change the bar width and the text position.

@danasilver
danasilver / README.md
Last active July 16, 2016 00:31
Retina Canvas Map

A retina-ready map rendered with D3 on a canvas.

[user]
name = Dana Silver
email = dsilver1221@gmail.com
[diff]
renames = true
[color]
ui = true
[core]
editor = emacs
[alias]
@danasilver
danasilver / .block
Created April 4, 2016 01:27
Animated Ag
license: MIT
@danasilver
danasilver / .block
Last active March 4, 2016 03:10
Gaussian Blur
height: 504
license: MIT