cider

A channel dedicated to the Clojure Interactive Development Environment that Rocks (aka CIDER). :cider:
yh 2020-09-21T00:05:16.004300Z

Hi, I added [ring-cors "0.1.13"]in my dependencies. But, in core.clj , cider cannot autocomplete the ring.middleware.corswhen I try to require it. Anyone how to fix it? (`clojure-lsp` can find the ring.middleware.cors candidate)

practicalli-john 2020-09-21T07:42:53.004500Z

Unless you have some form of hot-load library to load in new dependencies into a running REPL, the the REPL should be restarted (stop, start) to pick up the new dependency.

yh 2020-09-21T17:43:34.015300Z

Thanks @jr0cket. I am doing the (stop, start) approach, and can load the namespace successfully. The problem is there is no autocompletion of ring.middleware.cors from cider’s company mode (after injection). It is not really a big deal. I am just wondering whether there are some easy fix for the autocompletion.

2020-09-21T19:05:23.016500Z

How do I eval something in the code which yields a larger result, to be pretty-printed to the REPL - sort of equivalent to C-x e..?

2020-09-22T14:24:27.022900Z

Thanks!

2020-09-21T19:07:48.017Z

Sorry, I just saw that cider-insert-last-sexp-in-repl does the trick 🙂

dpsutton 2020-09-21T19:11:58.017300Z

there are some nice options around that to make it evaluate for you

dpsutton 2020-09-21T19:12:29.017500Z

(setq cider-invert-insert-eval-p t)
(setq cider-switch-to-repl-on-insert nil)

2020-09-21T22:54:58.017700Z

Thx @dpsutton