This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2019-11-05
Channels
- # announcements (5)
- # beginners (49)
- # boot (9)
- # calva (34)
- # cider (9)
- # clara (18)
- # clj-kondo (1)
- # cljsrn (7)
- # clojure (196)
- # clojure-dev (4)
- # clojure-europe (11)
- # clojure-france (3)
- # clojure-nl (13)
- # clojure-norway (2)
- # clojure-spec (8)
- # clojure-uk (85)
- # clojurescript (87)
- # clojurex (202)
- # core-logic (6)
- # data-science (6)
- # datomic (9)
- # dirac (1)
- # duct (93)
- # emacs (9)
- # events (1)
- # fulcro (22)
- # hoplon (30)
- # jackdaw (10)
- # keechma (1)
- # leiningen (5)
- # malli (17)
- # off-topic (9)
- # other-languages (3)
- # pedestal (7)
- # re-frame (3)
- # reagent (5)
- # reitit (9)
- # remote-jobs (6)
- # rewrite-clj (80)
- # ring (2)
- # shadow-cljs (191)
- # tools-deps (54)
- # vim (14)
- # xtdb (7)
thheller is specifically talking about a web app. you would have to send all of the code for the CLJS compiler to the browser, as well as not be able to optimize away any of your code because that could break things without knowing all of the code that will be executed
lumo doesn’t care as much because when you install it, it installs the CLJS compiler once on your system and it works only a desktop or server. for a web app, every user would download and run the compiler every time they visited your site, including people on mobile devices
@ptaoussanis, are you alive ?
Just a friendly reminder — it’s considered bad form in this Slack to @ people who are not currently active in a channel.
I want to export a dom node as an image. I looked at this some years ago and then found https://github.com/tsayen/dom-to-image. Would that still be a good choice in 2019?
We've been using it in lively.next for creating previews of objects users create which can be anything, including canvas nodes and stuff like google maps. Worked and works pretty well for this, some CSS transformations and props can be a bit glitchy. https://github.com/LivelyKernel/lively.next/blob/master/lively.morphic/rendering/morph-to-image.js
"real" objects at the top, dom-to-image renderings below.
if I remember correctly, dom nodes are removed while rendering so if you render a node that is on screen it'll disappear
I also vaguely remember that there was an issue with images / iframes from other domains when those don't do cors.
@U08LZDL1H Hi. I'm using the library, but I'm having issues with rendering font-awesome icons. Did you run into this?
just tested it and it seems to work fine with our (old) version of dom-to-image. left are font-awesome icons (also an old version from 2017) rendered via css and right a png image
OK. I just discovered the issue. Will post a link to the Github issue when I've finished it.
This seems to be the continuing fork: https://github.com/1904labs/dom-to-image-more#readme
https://stackoverflow.com/questions/58710273/basic-render-props-translation-to-reagent
@jstuartmilne answered on SO
Can somebody past an example how to deploy CljureScript library using deps.edn to Clojars?
I guess with https://github.com/slipset/deps-deploy but what about pom.xml
etc.?
The best if it can be example in github actions 🙂
Clojars is a Maven repo and Maven does not know anything about deps.edn
clojure -Spom
env CLOJARS_USERNAME=username CLOJARS_PASSWORD=password clj -A:deploy
Is it all?
It is my first time deploying to Clojars. No compilation before, to js -> cljs or other steps? Is it as simple as that?If not compile what is this jar file?
{:deploy {:extra-deps {deps-deploy {:mvn/version "RELEASE"}}
:main-opts ["-m" "deps-deploy.deps-deploy" "deploy"
"path/to/my.jar"]}}
https://github.com/slipset/deps-deploy#usageBut I would like to know how to do deploy to clojars
with deps.edn
. I will appreciate if somebody can paste an example 🙂
@U4YGF4NGM are you sure there is no cljs compilation before push to clojars?
But I would like to know how to do deploy to clojars
with deps.edn
. I will appreciate if somebody can paste an example 🙂
Hi guys, I am facing issue while installing clojure inside the docker..any pointers please. I am trying to install it with Java 11
https://hub.docker.com/_/clojure use ready one
I am working on tap-mssql for pipelinewise that is written in clojure language. To create an image of my pipelinewise doker I need to install clojure as well that requires leiningen (RUN curl https://raw.githubusercontent.com/technomancy/leiningen/stable/bin/lein > lein && mv lein /usr/local/bin/lein && chmod a+x /usr/local/bin/lein). when it installs clojure it is giving this error java.io.IOException: Cannot run program "/usr/lib/jvm/java-8-openjdk-amd64/jre/bin/java" (in directory "/pipelinewise/.virtualenvs/tap-mssql"): error=2, No such file or directory at java.lang.ProcessBuilder.start (ProcessBuilder.java:1128) java.lang.ProcessBuilder.start (ProcessBuilder.java:1071) java.lang.Runtime.exec (Runtime.java:591) jdk.internal.reflect.NativeMethodAccessorImpl.invoke0 (NativeMethodAccessorImpl.java:-2) jdk.internal.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:62) jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43) java.lang.reflect.Method.invoke (Method.java:566) clojure.lang.Reflector.invokeMatchingMethod (Reflector.java:167) clojure.lang.Reflector.invokeInstanceMethod (Reflector.java:102) leiningen.core.eval$sh.invokeStatic (eval.clj:179) leiningen.core.eval$sh.doInvoke (eval.clj:173) clojure.lang.RestFn.applyTo (RestFn.java:137)
I have version JAVA 11 installed but is it checking for 8..
here is how I install java + lein in my testing docker image (based on ubuntu): https://github.com/binaryage/dirac/blob/master/test/docker/Dockerfile
Just thinking… or maybe I shouldn’t care about clojars and just let people use hashes for library in deps.edn? Probably not a common standard. Is it? What is the current standard? As I understand I should deploy to clojars. Should I?
It depends upon your target audience. I would guess that to reach a wide audience of Clojure developers, deploying to either Clojars or Maven central will enable those who use boot or Leiningen to use your JAR file, whereas deploying source code only to a public git repo will limit your audience to those who use tools.deps.
I have not used it, but this wiki page of deps.edn based tools: https://github.com/clojure/tools.deps.alpha/wiki/Tools mentions deps-deploy with the description "A Clojure library to deploy your stuff to clojars"
That is why I would like to see example to not lose hours of my life to figure out things 🙂
There is a #tools-deps channel that might be a better target audience for your question
Personally I like to choose material-ui or different ready design to use instead of making everything myself from the beginning
in this product we already have a design language. so ideally something that is just a tooltip without bringing in others is a requirement
Unfortunately I can’t recommend you such a solution. I don’t use library only for tooltip. Maybe just add a few lines of CSS?
that's what we've been doing. but that runs into issues with overflows and if your tooltip is near the window edge
yeah. this is the principle issue we are trying to solve. refining the existing solution
probably you can check source code of bootstrap twitter tooltip or material-ui and rewrite it in clojurescript
Is there a quick way to unload a require , eg remove http
from the namespace after (require '[httplib.client :as http])
@kwladyka I use deps.edn in all of my newer projects for development, but I also mirror the deps in a project.clj which I use to build uberjars and deploy. Contributors can use either tool for development.
i think there's also a lein plugin that will use deps.edn
as the single source of truth for deps
I hope eventually tools.deps can be used within all those other tools so they can support git deps out of the box
@borkdude why not https://github.com/seancorfield/depstar and https://github.com/slipset/deps-deploy ?
I'm not suggesting not to use those, I just shared what I've been doing for several projects, just 2 cts 🙂