Jeb A. Beich
Panama City, FL
jebbeich (at) gmail (dot) com
(352) 213-7344
2000 Enterprise Java - 2002 J2ME - 2005 Python/.Net - 2008 Android - 2012 Clojure
; | |
https://floobits.com/r/err/err-clj/ |
;; | |
;; NS CHEATSHEET | |
;; | |
;; * :require makes functions available with a namespace prefix. | |
;; | |
;; * :use makes functions available without a namespace prefix | |
;; (i.e., refers functions to the current namespace). | |
;; | |
;; * :import refers Java classes to the current namespace. | |
;; |
## Using Emacs CIDER as the Figwheel REPL tool | |
project.clj should have this line: | |
``` | |
:figwheel { :nrepl-port 7888 } | |
``` | |
At the defproject-level. | |
It enables external tools to connect to the Figwheel REPL. To connect |
(defn render-squares | |
[component props] | |
(let [svg (-> js/d3 (.select (dom/node component))) | |
data (clj->js (:squares props)) | |
selection (-> svg | |
(.selectAll "rect") | |
(.data data (fn [d] (.-id d))))] | |
(-> (.enter selection) | |
(.append "rect") | |
(.style "fill" (fn [d] (.-color d))) |
I hereby claim:
To claim this, I am signing this object:
/* | |
(ns ch-market-place.core-test | |
(:require [clojure.test :refer :all] | |
[ch-market-place.core :refer :all])) | |
;; Here are the minimal inputs you should use for your test | |
;; cases. These test cases must be shown to work in your program: | |
;; Scan these items in this order: ABCDABAA; Verify the total price is | |
;; $32.40. |
Unsorted notes on Fulcro RAD.
If you have a :ref
attribute, you typically do not want to display it directly, i.e. its ident, but a more display-friendly prop of the child entity. This is handled automatically for you by Pathom, you only need to specify the attribute you want.
Let's assume you have a Person
entity with the ref attribute person/home-address
with the target address/id
. You can simply have ro/columns [person/name ... address/city address/country]
(assuming these attributes are defined and have :address/id
among their ao/identities
). Pathom can navigate from person/home-address -> address/id -> address/city etc.