Permalink
Switch branches/tags
Nothing to show
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
37 lines (26 sloc) 540 Bytes
(ns components-example.model
(:require [schema.core :as s]))
(def Name
{:first s/Str
:last s/Str})
(def demographics
{[:demographics :mrn]
s/Str
[:demographics :name]
Name
[:demographics :dob]
#?(:clj java.util.Date
:cljs js/Date)
[:demographics :address :province]
(s/enum "AB" "BC" "MB" "NB" "NL" "NS" "NT" "NU" "ON" "PE" "QC" "SK" "YT")})
(def vitals
{[:vitals :weight]
s/Num
[:vitals :height]
s/Num
[:vitals :bmi]
s/Num})
(def model
(merge
demographics
vitals))