lein-figwheel icon indicating copy to clipboard operation
lein-figwheel copied to clipboard

Unable to change Figwheel server-port

Open zendevil opened this issue 5 years ago • 1 comments

I am changing the server port of Figwheel like so:

{:builds [
                                           {:id           "ios"
                                            :source-paths ["src" "env/dev"]
                                            :figwheel     {:server-port 3450}
                                            :compiler     etc..
                                  } etc...]

But this gives me the error:

The key :server-port at (:all-builds 0 :figwheel) is on the wrong path.

  {:all-builds
   [{:figwheel
     {:server-port 3450
      ^---- The key :server-port has been misplaced
      }}]}

The :server-port key should probably be placed like so: 

  {:figwheel-options
   {:server-port 3450
    ^---- The key :server-port should probably be placed here
    }}

What am I doing wrong?

zendevil avatar Feb 24 '20 01:02 zendevil

@zendevil, i don't know your figwheel version but you should define :figwheel as a key under the defproject declaration.

(defproject myproject "0.1.0"
  ;; some definitions here
  :figwheel { 
    :server-port 3450
    :css-dirs "resources/public/css"
    :ring-handler some.nice/handler }
 ;; rest of the definitions
)

mengu avatar Apr 27 '20 20:04 mengu