Last active
August 29, 2015 14:25
-
-
Save mhuebert/3f6a9f4483ccdfccf318 to your computer and use it in GitHub Desktop.
CLJS javascript dependency load order?
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
; I want to use the files referenced in deps.cljs | |
; - CodeMirror must run before -overlay, -subpar, and -match-brackets. | |
(ns my-project.core | |
(:require | |
[CodeMirror] | |
[CodeMirror-overlay] | |
[CodeMirror-subpar] | |
[CodeMirror-match-brackets] | |
[reagent.core :as r :refer [cursor]] | |
; ... | |
)) | |
; it does not matter what order I put CodeMirror, CodeMirror-overlay, | |
; CodeMirror-subpar, etc. - they always load in the same (wrong) order. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
; this is in src/ of the CLJS library I want to use | |
{:foreign-libs | |
[{:file "codemirror/codemirror.js" | |
:provides ["CodeMirror"]} | |
{:file "codemirror/overlay.js" | |
:provides ["CodeMirror-overlay"]} | |
{:file "codemirror/subpar-with-keymap.js" | |
:provides ["CodeMirror-subpar"]} | |
{:file "codemirror/match-brackets.js" | |
:provides ["CodeMirror-match-brackets"]} | |
] | |
:externs ["codemirror/codemirror-externs.js"]} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment