This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2019-01-18
Channels
- # aleph (1)
- # announcements (2)
- # aws (4)
- # beginners (73)
- # boot (2)
- # boot-dev (3)
- # cider (6)
- # cljs-dev (40)
- # clojure (64)
- # clojure-austin (2)
- # clojure-belgium (1)
- # clojure-dev (25)
- # clojure-estonia (1)
- # clojure-europe (16)
- # clojure-italy (11)
- # clojure-nl (4)
- # clojure-spec (90)
- # clojure-sweden (2)
- # clojure-uk (105)
- # clojurescript (58)
- # core-async (10)
- # cursive (23)
- # data-science (1)
- # datascript (3)
- # datomic (14)
- # duct (11)
- # fulcro (48)
- # graphql (1)
- # hyperfiddle (3)
- # kaocha (95)
- # liberator (1)
- # lumo (6)
- # nrepl (1)
- # off-topic (14)
- # onyx (2)
- # overtone (8)
- # portkey (3)
- # re-frame (31)
- # reagent (6)
- # shadow-cljs (185)
- # sql (12)
- # tools-deps (6)
- # vim (6)
- # yada (224)
I have a ring app which uses mount to refresh stateful components. How do I refresh the server from a running REPL in cursive?
(mount/stop #'server) (mount/start #'server)
, or just clojure.tools.namespace.repl/refresh
if you changed code and it affects the server, because the server will be restarted automatically
should i run that command in a REPL running in cusrive/IntelliJ or ? command line ?
i am super newbie and you can picture a squid flailing in the ocean to describe me apptitude with clojre right now
i loaded dev.user.clj file into the repl and with that command (mount/start .. ) i got N-> o such namespace: mount, ...
even though mount is required and declared in the require section of dev.user
sure, alias it
(require '[mount.core :as mount])
yes, you should run it from the repl
also you should switch to the namespace where the server is, or refer to it
assuming it is my.app.server
, (in-ns 'my.app.server)
and assuming you want to stay in the user
ns, (require '[my.app.server :as server])
and then (mount/start #'server/server)
trying
what do you mean by my.app.server ? i am aiming to run server locally for development
thanks for your help though .. i think what your telling me is correct, i am using datomic though so that is my sticking point. if it were not for that library ( not loading ) it would work fine
ok so you say you have a server as a stateful component. that component must be in a namespace
that namespace is what I mean by my.app.server
, I don't know which name it has in your app
@U5LPUJ7AP thanks again for your help/time .. i think i got it ( i set up a REPL and had to set the alias to -> dev <- so it would be able to find the datomic libraries and i was able to mount/start the server
Hi @cfleming We’ve been doing some work involving tools.deps
and we sometimes depend on sub-modules (sub-directories really). I have noticed that Cursive (wrongly) highlights some valid occurrences of symbols. Is there any reason you would mark those as invalid ?
@gphilipp while clojure will allow you to use a symbol with multiple slashes in it, those are considered invalid symbols according to the language spec https://clojure.org/reference/reader#_symbols. If you try the same symbol in clojurescript instead, you would get that "Invalid Symbol" exception.