Skip to content

Instantly share code, notes, and snippets.

@tiensonqin
Last active July 31, 2018 09:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tiensonqin/17d40da231e6e71ada0c7d7a83f33997 to your computer and use it in GitHub Desktop.
Save tiensonqin/17d40da231e6e71ada0c7d7a83f33997 to your computer and use it in GitHub Desktop.
Parse error. Duplicate parameter name "body_format"
(ns cljs-duplicate-parameter.core)
(defn reproduce [{:keys [body_format]}]
(let [body-format body_format]
(fn []
(prn body-format))))
(reproduce {:body_format :asciidoc})
(defn ^:export init []
;; init is called ONCE when the page loads
;; this is called in the index.html and must be exported
;; so it is available even in :advanced release builds
(js/console.log "init"))
(defn stop []
;; stop is called before any code is reloaded
;; this is controlled by :before-load in the config
(js/console.log "stop"))
@tiensonqin
Copy link
Author

Error:

➜ cljs-duplicate-parameter yarn release
yarn run v1.1.0
warning package.json: No license field
$ shadow-cljs release app;
shadow-cljs - config: /home/tienson/codes/clj/cljs-duplicate-parameter/shadow-cljs.edn cli version: 2.4.25 node: v8.5.0
shadow-cljs - connected to server
[:app] Compiling ...
Closure compilation failed with 1 errors
--- cljs_duplicate_parameter/core.cljs:7
Parse error. Duplicate parameter name "body_format"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment