Fork me on GitHub

REPLey: a web REPL made with Ripley

🎉 14

“Language: CSS” 😄 I need to minify the CSS because there’s more of it than Clojure code here

clojure-spin 8
😄 4
Michaël Salihi18:06:06

If minifying CSS is not suffisant, you can also put a .`gitattributes` file excluding some language like I did on this project.

thanks 2

I made an intro video to better see what it is about


I've been playing around with various similar tools this week and REPLey is definitely an interesting project. Implementing navigation (with breadcrumbs!) similar to is really cool. Thank you! Some thoughts/comments: • Is CLJS support planned? • I like how toggle state and truncation works by default. You get enough of a sense of the tapped value, then FULL gives you all info without having to unfold nested values. (Something that bugs me about Portal.) • Ability to reference and manipulate tapped values from the REPL box would be cool. • Button to clear all tapped values. • More prominently displaying the time and origin of the tap would be nice. shadow's inspect does this and I quite like 'logs' from Portal (see attached img; though ms precision would be better). Ability to "label" taps could be a nice addition. BTW, I tried b85a1f0ccd80215919d941a7e7fe488dac082694 over the weekend. However, the latest commit as of now, throws:

; Syntax error macroexpanding h/html at (repley/main.clj:106:5).
; No garden compiler found, add garden to deps to support CSS compilation


Thanks for trying it out.


Cljs is not planned as ripley, the underlying ui library ia strictly server side rendering


Perhaps I should've phrased it more clearly. I meant the ability to add a tap on CLJS side. I wonder if that is doable. A quick glance at, it seems that taps basically send HTTP requests to the server.


That sounds doable.

👍 1

added a timestamp (and duration if value was evaluated by REPLey)... can be configured with :timestamp-format (nil to disable)

👍 1

the latest commit should start, added a badge showing latest github actions test status


Still seeing the garden-related error with latest commit.


by running clj -M:dev ?


Ripley supports garden styling, but doesn't provide the dependency (so that's why you can get that, but REPLey isn't using those)


I included it as a library. Requiring repley.main throws.


ok, accidentally had 1 garden style there... can you try with the latest commit? committed just now


great, thanks for reporting it


Are you aware of any limitations with the EDN visualisation navigation? Simple stuff like {:foo {:bar 1}} works, but with a larger map from my server it doesn't 🙂


yes, edn stuff needs to have the key read able


if you have minimal samples of what fails in navigation, it would be useful if you can report that as an issue in github


I'm trying to find out know, will report.

thanks 1

It seems to work before I press "full".


yes, seems to be missing the id when rerendering without truncation


that should be a quick fix

👍 1

Fixed, thanks. A thought: maybe navigation should not reset the truncation?


currently the truncation is component local state and thus navigation removes and creates a new component... could be moved to another place


I agree, it certainly could remember that you expanded a given result already


Just a thought. Quite feasible others would like it to reset 🙂


I could probably quibble about minor details of the UI, but that's not important at this point. I'll try to look into what it would take to support CLJS taps. I'd quite like to use REPLey for my projects 🙂


would just an HTTP endpoint to receive edn formatted values be enough? that should be then easy to integrate into a cljs project


I think that's how Portal does it, yeah.


I can add the endpoint at least, I'm not currently doing cljs so don't have a shadow build to test with


Great. With the endpoint in place, I could play around.


added a receive endpoint, you can call it like

% curl -X POST -d "{:hello \"there\" :meaning-of-life 42}" 
it returns 204 no content always

awesome 1

I have it working. Are you interested in a PR? (There's not much to it.)


One issue I'm encountering now: No reader function for tag gdb/ident.


Well that is the problem with a generic edn parsing, dont have any specific reader tags installed


Can we add edn readers to the repley-handler config or is this more of a userland concern?


I think it would be good to have in the config

phronmophobic05:06:06 A wrapper for libclang and a generator that can turn c header files into clojure apis. Version 1.0 • Use javacpp for pulling native dependencies via maven • Bug fix for structs with bitfields • Simplify def-api into smaller pieces I've been using clong for several different projects and I think it's ready for the 1.0 release 🎉

🎉 31
👀 5
🙀 2
Kelvin19:06:43 version 0.5.0 is now out: • Remove Clojure(Script) and data.json as library dependencies, and update core.match and Instaparse dependencies • Update the apply-value function to support the following optional args: ◦ :wildcard-append?: Dictates if wildcard values should be appended to the end of existing seqs. Default false (this is a breaking change from the previous default behavior). ◦ :wildcard-limit: Dictates how many wildcard paths should be generated. If it is not present then the entire coll gets overwritten at each wildcard location if :wildcard-append? is false; if it’s true, one new path gets appended. • Add an apply-multi-value function that is similar to apply-value, except that it must accept a collection of values that will be applied in order. Returns once the values or the available path seqs runs out. Also accepts :wildcard-append? and :wildcard-limit. • Add a speculate-paths function that acts like get-paths but is not stopped by missing values. Also accepts :wildcard-append? and :wildcard-limit. • Various internal namespace changes and implementation refactors

🎉 12