mirror of
https://github.com/penpot/penpot.git
synced 2025-01-23 23:18:48 -05:00
misc(frontend): minor improvements on tools.clj script
This commit is contained in:
parent
93b4258f02
commit
1fbd353001
1 changed files with 35 additions and 18 deletions
|
@ -72,26 +72,43 @@
|
||||||
:output-dir "target/tests/main"
|
:output-dir "target/tests/main"
|
||||||
:optimizations :none)))
|
:optimizations :none)))
|
||||||
|
|
||||||
|
|
||||||
|
(def figwheel-builds
|
||||||
|
{:main {:id "main"
|
||||||
|
:options (merge default-build-options
|
||||||
|
(get-output-options "main" false true))}
|
||||||
|
:view {:id "view"
|
||||||
|
:options (merge default-build-options
|
||||||
|
(get-output-options "view" false true))}
|
||||||
|
:worker {:id "worker"
|
||||||
|
:options (merge default-build-options
|
||||||
|
{:target :webworker}
|
||||||
|
(get-output-options "worker" false true))}})
|
||||||
|
|
||||||
|
(def figwheel-options
|
||||||
|
{:open-url false
|
||||||
|
:load-warninged-code true
|
||||||
|
:auto-testing false
|
||||||
|
:css-dirs ["resources/public/css"
|
||||||
|
"resources/public/view/css"]
|
||||||
|
:ring-server-options {:port 3449 :host "0.0.0.0"}
|
||||||
|
:watch-dirs ["src" "test"]})
|
||||||
|
|
||||||
(defmethod task "figwheel"
|
(defmethod task "figwheel"
|
||||||
[args]
|
[& args]
|
||||||
(figwheel/start
|
(figwheel/start
|
||||||
{:open-url false
|
figwheel-options
|
||||||
:load-warninged-code true
|
(:main figwheel-builds)
|
||||||
:auto-testing false
|
(:view figwheel-builds)
|
||||||
:css-dirs ["resources/public/css"
|
(:worker figwheel-builds)))
|
||||||
"resources/public/view/css"]
|
|
||||||
:ring-server-options {:port 3449 :host "0.0.0.0"}
|
(defmethod task "figwheel-single"
|
||||||
:watch-dirs ["src" "test"]}
|
[[_ name]]
|
||||||
{:id "main"
|
(when-let [build (get figwheel-builds (keyword name))]
|
||||||
:options (merge default-build-options
|
(figwheel/start
|
||||||
(get-output-options "main" false true))}
|
figwheel-options
|
||||||
{:id "view"
|
build
|
||||||
:options (merge default-build-options
|
(:worker figwheel-builds))))
|
||||||
(get-output-options "view" false true))}
|
|
||||||
{:id "worker"
|
|
||||||
:options (merge default-build-options
|
|
||||||
{:target :webworker}
|
|
||||||
(get-output-options "worker" false true))}))
|
|
||||||
|
|
||||||
;;; Build script entrypoint. This should be the last expression.
|
;;; Build script entrypoint. This should be the last expression.
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue