Skip to content

Instantly share code, notes, and snippets.

View escherize's full-sized avatar

bryan escherize

View GitHub Profile
# focus window
shift + cmd - a : chunkc tiling::window --focus west
shift + cmd - s : chunkc tiling::window --focus south
shift + cmd - w : chunkc tiling::window --focus north
shift + cmd - d : chunkc tiling::window --focus east
# warp window
shift + cmd - j : chunkc tiling::window --warp west
shift + cmd - k : chunkc tiling::window --warp south
shift + cmd - i : chunkc tiling::window --warp north
(ns scratch.memo)
(defn add-one-api-call [n]
(println "Getting Request for: " n)
(Thread/sleep 1000)
{:response (+ 1 n)})
(defn request [& ns]
(let [cached-api-call (memoize add-one-api-call)]
(mapv cached-api-call ns)))
(ns surgical.examples.temperature-change
(:require [rum.core :as rum]))
;; Compare to
;; https://facebook.github.io/react/docs/lifting-state-up.html
(defonce app-state (atom {:temp "0" :scale :f}))
(def scale-names {:f "Farienheit" :c "Celcius"})
(defn ->celcius [far] (* (- far 32) (/ 5 9)))
Unstaged
modified transmit-client/dev/fe_figwheel.clj
@@ -7,7 +7,12 @@
(def fe-config
(as-> (:data master-config) $
- (merge $ {:figwheel-options {:server-port 3460 :css-dirs ["app/resources/public/css"]}
+ (merge $ {:figwheel-options {:server-port 3460
+ :css-dirs ["app/resources/public/css"]
+ :nrepl-port 7666
(ns scratch.bowling
(:require [clojure.core.match :refer [match]]))
(def strike? #(= (first %) \X))
(defn ->n [n] ((zipmap [\- \1 \2 \3 \4 \5 \6 \7 \8 \9 \X] (range 11)) n "/"))
(defn ->frames [game-str]
(loop [frames [] trials game-str]
(if-not (empty? trials)
(recur (conj frames (take 3 trials))
(ns cljs-horizon.app
(:require [reagent.core :as reagent :refer [atom]]
[clojure.string :as str]))
;; horizon library
(def horizon (js/Horizon))
;; db table
(def chat (horizon "messages_four"))

Resume

Projects

TextMeTheLink.com

SaaS to help companies and individuals aquire downloads for their app.

We provide a textbox widget where visitors can enter their phone number and recieve a text message with a link to our clients’ app on the App Store or Google Play Store.

Also a ClojureScript SPA

Static app which runs a full featured ClojureScript compiler (cljs-in-cljs) in the browser.

Ability to save and load fiddles by (ab)using github gists.

Slides availiable at escherize.com/cljsfiddle_talk

Show: Clojure Java REPL Tooling Duplicates All (15 frames hidden)
2. Unhandled clojure.lang.Compiler$CompilerException
Error compiling src/one-love-sample/core.clj at (4:1)
Compiler.java: 7391 clojure.lang.Compiler/load
REPL: 1 user/eval21954
REPL: 1 user/eval21954
Compiler.java: 6927 clojure.lang.Compiler/eval
Show: Clojure Java REPL Tooling Duplicates All (28 frames hidden)
2. Unhandled clojure.lang.Compiler$CompilerException
Error compiling one/love/command/ast.clj at (54:1)
Compiler.java: 7239 clojure.lang.Compiler/load
RT.java: 371 clojure.lang.RT/loadResourceScript
RT.java: 362 clojure.lang.RT/loadResourceScript
RT.java: 446 clojure.lang.RT/load
Show: Clojure Java REPL Tooling Duplicates All (22 frames hidden)
2. Unhandled clojure.lang.Compiler$CompilerException
Error compiling one/love/command.clj at (1:1)
core.clj: 5630 clojure.core/throw-if
RestFn.java: 442 clojure.lang.RestFn/invoke
core.clj: 5716 clojure.core/load-lib
RestFn.java: 142 clojure.lang.RestFn/applyTo