On Wed, Jul 23, 2014 at 10:08 PM, Brent Millare <brent.mill...@gmail.com>
wrote:

> I forgot to include in the snippet, that I would do something like
>
> (def live-repl-client (cljs.repl/channel-repl repl-env))
>
> When you say channel-repl/cider-function, do you mean
> user/live-repl-client?
>

Yes, exactly.


>
> I don't quite understand what you mean by (prefix).
>

*prefix* was just the variable taken from the interactive function.

(defun cider-eval-cljs-defun-at-point (&optional *prefix*)
  "Evaluate the current toplevel form, and print result in the minibuffer.
With a PREFIX argument, print the result in the current buffer."
  *(interactive "P")*
  ...)




>
> What I want is just to be able to evaluate clojurescript code in a buffer
> just like I do with regular clojure code. This way I get the same access to
> large chunks of scratch code that I can only easily access when I have it
> in an emacs buffer.
>

Ah, ok. I think austin gives this to you. I'll need to double-check.


>
> I don't really know much about piggieback or austin. I'd prefer to stay as
> close to upstream/vanilla clojurescript as possible.
>
>
But this is a fair point, as Austin <https://github.com/cemerick/austin/>
took some doing for me to set up. If it helps, I created a simple component
(gist here <https://gist.github.com/twashing/d95c7b9506d2900f1e23>) that
puts the repl-env creation into a *Component
<https://github.com/stuartsierra/component>*. There's also a helper
function that lets you deliver an HTML resource, with a
'clojure.browser.repl.connect' back to your repl-env (in your browserrepl).


Cheers
Tim

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to