Skip to content

Instantly share code, notes, and snippets.

Dave Shepard kynatro

Block or report user

Report or block kynatro

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
kynatro / params.js
Last active Aug 9, 2018
URL Parameters as an object
View params.js
// Could be any query string
var parameters =;
var parametersObject = parameters
// Skip the "?" at the beginning of the string
// Split into an array of individual parameters
// Split each parameter into an array of its key and value
kynatro / Preferences.sublime-settings
Last active Apr 13, 2018
Sublime Text Configuration
View Preferences.sublime-settings
kynatro / rcomp.sublime-snippet
Created Jan 5, 2018
React Component Sublime Snippet
View rcomp.sublime-snippet
<content><![CDATA[import React, { Component } from 'react'
import { connect } from 'react-redux'
import { withRouter } from 'react-router-dom'
const mapStateToProps = (state, ownProps) => {
return {
location: ownProps.location
kynatro / nginx.conf
Created Jun 1, 2015
nginx web font Content-Type specifications
View nginx.conf
location ~* \.(woff)$ {
add_header Content-Type "application/font-woff";
location ~* \.(otf)$ {
add_header Content-Type "application/font-sfnt";
location ~* \.(eot)$ {
add_header Content-Type "application/";
location ~* \.(ttf)$ {
View generate-codes.rb
# How many codes to make
quantity = 30000
# Path to the file to be written
dest_file = 'codes.csv'
codes = []
quantity.times do
codes << "#{SecureRandom.hex(6)}".upcase
kynatro / Gruntfile.automated.js
Last active May 24, 2017
Grunt + Browserify + alias/external = common module bundles
View Gruntfile.automated.js
const path = require('path')
module.exports = function(grunt) {
const config = {
browserify: {
options: {
transform: [
['babelify', { presets: ['es2015', 'es2016'] }]
kynatro /
Last active Apr 13, 2017
TKTK Outstanding Copy Highlighter


Tktk short for "To Come" in publishing is a simple placeholder highlighting library. Load this file on your latest project to highlight all the areas that still need copy, links, or final imagery. To highlight items, simply do one of the following:

Images: Either add a tktk class to the img tag or add #tktk to the image source.

Copy: Either add a tktk class to the element, or start the copy with "tktk"

For all elements that are "to come", copy will be highlighted in a nice, obvious magenta and images bordered in a 2px magenta border (using box-shadow so as not to affect layout).

kynatro /
Last active Mar 9, 2017 — forked from jamiehs/
In This Language (add your comments or suggestions)


foo bar baz qux

#Required Output

Hello Foo
Hello Bar
Hello Baz
Hello Qux
kynatro / app.jsx
Last active Jan 17, 2017
React + Redux Contrived Primer
View app.jsx
// Destructure the Provider component and connect method from the
// react-redux module. The component wraps your React application in
// the code necessary to work properly with state and prop updates
// from Redux. The connect method allows you to connect individual
// React components to Redux for Redux store to prop mapping.
import { Provider, connect } from 'react-redux'
// Destructure the createStore method from the core redux module
// This method allows you to create your global store to house all your
// state values and your reducers to update state values
import { createStore } from 'redux'
kynatro /
Last active Nov 23, 2016
Middleman Embedded SVG Ruby Helper

Embedded SVG Helper

A simple helper function that makes inline SVG embedding simple! Just add the asset_helpers.rb file to your Middleman project's helpers folder and it will automatically be loaded and made available to you in your templates. From there, simply call:

<%= embedded_svg("my-asset.svg") %>

And your SVG asset content will be embedded inline in your template. You can also pass the following options to the helper to add additional attributes to the SVG tag itself:

You can’t perform that action at this time.