 (defmethod config/target-spec `process [_]
   (s/spec ::target))
 
-(defn create-module [state {:keys [exports output-to] :as config}]
+(defn create-module [state {:keys [exports output-to umd-root-name] :as config}]
   {:pre [(data/build-state? state)
          (map? config)
          (or (qualified-symbol? exports)

        ;; based on https://github.com/umdjs/umd/blob/master/templates/returnExports.js
        [prepend append]
        (-> (slurp (io/resource "shadow/build/targets/umd_exports.txt"))
            (str/split #"//CLJS-HERE"))]

    (-> state
        (assoc :node-config node-config)

      simple-keyword?
      shared/unquoted-qualified-symbol?)))

(s/def ::umd-root-name shared/non-empty-string?)

(s/def ::target
  (s/keys
    :req-un
    [::exports
     ::shared/output-to]
    :opt-un
    [::shared/output-dir
     ::umd-root-name]
    ))

(defmethod config/target-spec :node-library [_]
