Skip to content

Instantly share code, notes, and snippets.

@dcunited001
dcunited001 / designer.html
Last active August 29, 2015 14:06
designer
<link rel="import" href="../paper-tabs/paper-tabs.html">
<link rel="import" href="../paper-tabs/paper-tab.html">
<link rel="import" href="../paper-input/paper-input.html">
<link rel="import" href="../paper-radio-group/paper-radio-group.html">
<link rel="import" href="../paper-radio-button/paper-radio-button.html">
<polymer-element name="my-element">
<template>
<style>
@dcunited001
dcunited001 / designer.html
Last active August 29, 2015 14:06
designer
<!DOCTYPE html>
<html>
<head>
<link rel="import" href="../polymer/polymer.html">
<link rel="alternate" type="application/rss+xml" title="Site Feed" href="/index.xml" />
<title>Site Title</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
</head>
<body fullbleed vertical horizontal>
@dcunited001
dcunited001 / designer.html
Created September 19, 2014 23:27
designer
<link rel="import" href="../polymer/polymer.html">
<core-toolbar class="tall">
</core-toolbar>
@dcunited001
dcunited001 / designer.html
Last active August 29, 2015 14:06
designer
<link rel="import" href="../core-icon-button/core-icon-button.html">
<link rel="import" href="../core-toolbar/core-toolbar.html">
<core-toolbar id="core_toolbar">
<core-icon-button icon="menu" id="core_icon_button"></core-icon-button>
<div id="div" flex>Toolbar</div>
</core-toolbar>
@dcunited001
dcunited001 / 0_reuse_code.js
Last active August 29, 2015 14:06
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@dcunited001
dcunited001 / foo.clj
Created November 2, 2014 05:00
problems with sorting a map in clojure
;; here i'm not calling persistent/transient in a function and this array is sorted correctly
(def foo {:TAAAGCCTCTGTCC 8, :GAGTAAAACAGATT 1, :TAAAGTACTCAAGT 3, :ATAGTCACAGATTC 4, :CCGCCTCTGTCCGT 8, :CACAGATTCGTACT 2})
(def dataset "GTACTCAAGGCTAATAGTCGCTAATAGTCGCTAATAGTCGCCTCTGTCCGCTAATAGTCACAGATTCACAGATTCGCTAATAGTCGTACTCAAGACAGATTCGCCTCTGTCCGTACTCAAGGCTAATAGTCACAGATTCGCTAATAGTCGTACTCAAGTCGGAGTAAAGCCTCTGTCCGCTAATAGTCACAGATTCACAGATTCTCGGAGTAAAGCCTCTGTCCGCTAATAGTCGTACTCAAGTCGGAGTAAATCGGAGTAAAGCCTCTGTCCTCGGAGTAAAGTACTCAAGACAGATTCGCCTCTGTCCGCCTCTGTCCGTACTCAAGGCCTCTGTCCGCCTCTGTCCTCGGAGTAAAGTACTCAAGTCGGAGTAAAACAGATTCGTACTCAAGACAGATTCTCGGAGTAAAGCCTCTGTCCACAGATTCACAGATTCGTACTCAAGACAGATTCGCCTCTGTCCGCCTCTGTCCACAGATTCGCTAATAGTCTCGGAGTAAAGCCTCTGTCCGCTAATAGTCTCGGAGTAAAGCCTCTGTCCGCTAATAGTCACAGATTCGTACTCAAGGTACTCAAGACAGATTCGTACTCAAGTCGGAGTAAAGCCTCTGTCCTCGGAGTAAAGTACTCAAGTCGGAGTAAAGCTAATAGTCTCGGAGTAAAGCCTCTGTCCGCTAATAGTCGTACTCAAGACAGATTCTCGGAGTAAAGTACTCAAGTCGGAGTAAAGTACTCAAGGCCTCTGTCCTCGGAGTAAATCGGAGTAAAGTACTCAAGGCCTCTGTC
@dcunited001
dcunited001 / build-error
Last active August 29, 2015 14:20
gradle dex problems
Error:Execution failed for task ':app:dexDebug'.
> com.android.ide.common.internal.LoggedErrorException: Failed to run command:
/Users/dc/Library/Android/sdk/build-tools/21.1.2/dx --dex --no-optimize --output /Users/dc/AndroidStudioProjects/Voxxel/app/build/intermediates/dex/debug --input-list=/Users/dc/AndroidStudioProjects/Voxxel/app/build/intermediates/tmp/dex/debug/inputList.txt
Error Code:
3
Output:
warning: Ignoring InnerClasses attribute for an anonymous inner class
(org.custommonkey.xmlunit.DoctypeInputStream$1) that doesn't come with an
associated EnclosingMethod attribute. This class was probably produced by a
compiler that did not target the modern .class file format. The recommended
<nav class="navbar navbar-default navbar-fixed-top" role="navigation">
<div class="container-fluid">
<div class="navbar-header">
<button type="button" class="navbar-toggle" ng-click="navCollapsed=!navCollapsed">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<!-- TODO: extract site title -->
@dcunited001
dcunited001 / mocks.js
Created May 22, 2015 13:41
Frontend Mocks
//the service('res') around line 900 is a good example of functional programming w/ js
//mocking out the frontend's api's like this allows me to:
// - get a prototype up and running for a new startup as quickly as possible
// - ensure that the prototype appears to run very fast, as the API calls are mocked
// - free instances on heroku are very slow, which is a bad first impression of a product
// - avoid getting stuck in devops, pushing out an API
// - be capable of getting an API up as quickly as possible once I'm ready,
// - since the requests are mocked exactly as Rails would return them
// - experiment with various API frameworks,
@dcunited001
dcunited001 / basic_triangle.metal
Created September 14, 2015 13:13
basic triangle shader -- why does modulating w affect z??
#include <metal_stdlib>
using namespace metal;
struct BasicTriangleVertexIn {
float4 position;
float4 color;
};
struct BasicTriangleVertexOut {