mirror of
https://github.com/penpot/penpot.git
synced 2025-05-18 00:26:10 +02:00
🎉 Make the build to be config independent.
Loading the configuration dinamically using global variables defined in index.html.
This commit is contained in:
parent
1ce46a0ef8
commit
c09f281f58
6 changed files with 38 additions and 21 deletions
|
@ -28,20 +28,11 @@
|
|||
|
||||
;; --- Generic Build Options
|
||||
|
||||
(def closure-defines
|
||||
(let [url (some-> (:uxbox-api-url env)
|
||||
(str/trim))
|
||||
demo-warn (some-> (:uxbox-demo-warning env)
|
||||
(str/trim))]
|
||||
{'uxbox.config.url (if (nil? url) "http://localhost:6060" url)
|
||||
'uxbox.config.demo-warning (= "true" demo-warn)}))
|
||||
|
||||
(def default-build-options
|
||||
{:cache-analysis true
|
||||
:parallel-build true
|
||||
:language-in :ecmascript6
|
||||
:language-out :ecmascript5
|
||||
:closure-defines closure-defines
|
||||
:anon-fn-naming-policy :mapped
|
||||
:optimizations :none
|
||||
:infer-externs true
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue