[ClojureScript] Re: Let's make ClojureScript more approachable for beginners

2021-01-21 Thread Yehonathan Sharvit
Hello! I totally agree that allowing beginners to learn ClojureScript and experimenting with code in the browser bring a huge benefit and will increase ClojureScript usage. Klipse addresses this challenge by providing: - An online ClojureScript repl: http://app.klipse.tech/ - A way to embed

[ClojureScript] Re: Seeing libraries from eval in Clojurescript

2017-10-23 Thread Yehonathan Sharvit
I have answered your question in stackoverflow. If you need more details about how I solve this issue inside Klipse, please contact me in private. On Sunday, 22 October 2017 01:47:23 UTC+3, phil jones wrote: > > I have a problem seeing libraries from inside an eval-ed expression in >

[ClojureScript] Re: Test existing Javascript with Clojure spec

2017-05-05 Thread Yehonathan Sharvit
On Friday, 5 May 2017 01:12:10 UTC+3, José Manuel Aguirre wrote: > I would like to learn Clojurescript and I wonder if there is any way to do it > writing tests, using the spec, that targets functions or react components > already implemented in javascript? > > That way I can accomplish two

[ClojureScript] The 1st interactive om.next tutorial

2017-01-03 Thread Yehonathan Sharvit
http://read.klipse.tech/om-next-interactive-tutorial/ -- Note that posts from new members are moderated - please be patient with your first post. --- You received this message because you are subscribed to the Google Groups "ClojureScript" group. To unsubscribe from this group and stop

Re: [ClojureScript] Re: Variant macros with reader conditionals?

2016-12-04 Thread Yehonathan Sharvit
Also keep in mind that with self host clojurescript reader conditionals always branch to :cljs even for macros -- Note that posts from new members are moderated - please be patient with your first post. --- You received this message because you are subscribed to the Google Groups

[ClojureScript] core.match interactive tutorial - with KLIPSE

2016-10-25 Thread Yehonathan Sharvit
http://blog.klipse.tech/clojure/2016/10/25/core-match.html -- Note that posts from new members are moderated - please be patient with your first post. --- You received this message because you are subscribed to the Google Groups "ClojureScript" group. To unsubscribe from this group and stop

[ClojureScript] [ANN] codox-klipse-theme 0.0.1- Clojure[script] automatically generated live documentation

2016-10-10 Thread Yehonathan Sharvit
https://github.com/viebel/codox-klipse-theme codox is a great tool for generating API documentation from Clojure or ClojureScript source code. With the klipse theme for codox, you can make your codox documentation live and interactive powered by the KLIPSE

Re: [ClojureScript] Why isn't giving end-users a repl dangerous?

2016-09-25 Thread Yehonathan Sharvit
By the way, the klipse plugin does something similar. You might want to take a look at https://github.com/viebel/klipse On Mon, Sep 26, 2016, 00:44 mars0i <marsh...@logical.net> wrote: > On Sunday, September 25, 2016 at 3:10:29 PM UTC-5, Yehonathan Sharvit > wrote: > > There

Re: [ClojureScript] Why isn't giving end-users a repl dangerous?

2016-09-25 Thread Yehonathan Sharvit
There might me security issues if the website allows users to modify the contents of the page - like Wikipedia or clojuredocs.org. A malicious user might write cljs code that will do malicious actions that run on the browser of all your visitors On Sunday, 25 September 2016 19:47:03 UTC+3,

[ClojureScript] KLIPSE (repl + plugin) just hit the 400 stars on github!

2016-09-12 Thread Yehonathan Sharvit
KLIPSE (https://github.com/viebel/klipse) is both clojure[script] web repl and a plugin. The repl is at: http://app.klipse.tech The klipse plugin is a javascript tag that transforms static code snippets of an html page into live and interactive snippets: 1. Live: The code is executed in your

[ClojureScript] [ANN Y combinator] Lambda Calculus: Interactive Y combinator running in the browser

2016-08-09 Thread Yehonathan Sharvit
http://blog.klipse.tech/lambda/2016/08/07/pure-y-combinator-clojure.html This article is an attempt to share in an interactive way, one of the most aesthetic idea of computer science: the Y combinator. The Y combinator

[ClojureScript] Re: ANN: Klipse for Kids

2016-08-03 Thread Yehonathan Sharvit
Mars0i, as I see it interactivity is the key for effective learning - both for kids and adults. This is the whole point of Klipse - https://github.com/viebel/klipse. By the way, do you have any suggestion about how to make the errors less daunting? On Tuesday, 2 August 2016 20:52:30 UTC+3,

[ClojureScript] Re: ANN: Klipse for Kids

2016-08-03 Thread Yehonathan Sharvit
Thanks JvJ. I've fixed it. On Tuesday, 2 August 2016 22:47:41 UTC+3, JvJ wrote: > > Pretty good. However: In chapter 1, you might want to clear up the fact > that 7*8 is 7 x 8 early on. Kids may not be familiar with the * as a > multiplication symbol. I realize it's explained later, but it's

[ClojureScript] Re: Self-hosting Clojurescript - :context is important

2016-04-28 Thread Yehonathan Sharvit
It seems that when we pass :context :dummy, it behaves not like when not passing anything. (cljs/eval-str (cljs/empty-state) " (def x 12) (if 45 23 21)" "bla" {:eval cljs/js-eval :context :expr} identity) ; => {:error #error {:message "ERROR", :data {:tag :cljs/analysis-error}, :cause

[ClojureScript] [ANN] KLIPSE 0.4.2 - KLIPSE: a simple and elegant online cljs compiler and evaluator

2016-04-28 Thread Yehonathan Sharvit
KLIPSE: a simple and elegant online cljs compiler and evaluator Version 0.4.2 is live with the following additions: 1. more detailed errors - see for instance http://app.klipse.tech/?cljs_in=(a) 2. pretty print clojure outputs - see for instance http://tinyurl.com/klipse-pprint 3. static

Re: [ClojureScript] compile static-fns

2016-04-14 Thread Yehonathan Sharvit
It has been a long time It seems that now, static-fns true work fine also for special cases like REPL development. David, do you agree? Take a look here:

[ClojureScript] Self-host: in advanced compilation mode, cljs.js/compile-str causes a javascript error

2016-03-25 Thread Yehonathan Sharvit
I have opened a JIRA issue for that a couple of days ago, but nobody addressed the issue http://dev.clojure.org/jira/browse/CLJS-1604 Thanks. -- Note that posts from new members are moderated - please be patient with your first post. --- You received this message because you are subscribed

[ClojureScript] [ANN] Klipse 0.0.1 - a simple and elegant online cljs compiler and evaluator

2016-03-19 Thread Yehonathan Sharvit
We are happy to bring to the cljs community KLIPSE - a simple and elegant online cljs compiler and evaluator. You can give it a try here

Re: [ClojureScript] cljs.analyzer: how to use it?

2016-02-07 Thread Yehonathan Sharvit
I have opened a jira ticket for this issue: http://dev.clojure.org/jira/browse/CLJS-1565 On Mon, 25 Jan 2016 at 16:09 Yehonathan Sharvit <vie...@gmail.com> wrote: > I have an issue when requiring cljs.js and compiling in `:optimizations > :whitespace` > I get the following error

Re: [ClojureScript] function `arguments` object

2016-02-04 Thread Yehonathan Sharvit
On Tuesday, 2 February 2016 04:32:57 UTC+2, Herwig Hochleitner wrote: > Well, for multi-arity, you'd have to parse the argument tuples. I mean, > `(print ~args) will almost work, since most destructurings can also be > evaluated and printed, but not so for seq destructurings a la (defprint x >

Re: [ClojureScript] function `arguments` object

2016-02-01 Thread Yehonathan Sharvit
On Monday, 1 February 2016 21:26:48 UTC+2, Herwig Hochleitner wrote: > How about > > > (defmacro defprint [func-name args & body] >   `(defn ~func-name [~'& args#] >      (print args#) >      (let [~args args#] >        ~@body))) > ​ Thanks Herwig! It works perfectly Do you know how I can

[ClojureScript] function `arguments` object

2016-02-01 Thread Yehonathan Sharvit
I want to write a macro that defines a function like `defn` but also on each function call, prints the values of the arguments passed to the function. Is there a generic way in `cljs` inside a macro, to get the value of the arguments passed to a function, something like javascript `arguments`

Re: [ClojureScript] cljs.analyzer: how to use it?

2016-01-25 Thread Yehonathan Sharvit
I have an issue when requiring cljs.js and compiling in `:optimizations :whitespace` I get the following error in the browser: goog.require could not find: cljs.core$macros Any idea why it happens and how to solve it? On Thu, Jan 21, 2016 at 4:21 PM, Mike Fikes wrote: >

Re: [ClojureScript] Re: cljs.analyzer: how to use it?

2015-12-01 Thread Yehonathan Sharvit
https://github.com/cljsinfo/cljs-api-docs/blob/catalog/refs/library/cljs.js.md). > Here is a gist with a small example: > https://gist.github.com/mneise/36c0bbae83b19c056781 > > > > On Sunday, November 22, 2015 at 11:19:29 AM UTC-5, Yehonathan Sharvit > wrote: > > >

Re: [ClojureScript] Re: cljs.analyzer: how to use it?

2015-11-24 Thread Yehonathan Sharvit
jureScript in ClojureScript you need to use the cljs.js > namespace ( > https://github.com/cljsinfo/cljs-api-docs/blob/catalog/refs/library/cljs.js.md). > Here is a gist with a small example: > https://gist.github.com/mneise/36c0bbae83b19c056781 > > On Sunday, November 22, 2015 at 11:19:29

[ClojureScript] core.memoize for cljs?

2015-09-28 Thread Yehonathan Sharvit
Does anybody plan to implement core.memoize on cljs? https://github.com/clojure/core.memoize -- Note that posts from new members are moderated - please be patient with your first post. --- You received this message because you are subscribed to the Google Groups "ClojureScript" group. To

[ClojureScript] My cljs app is too big! Please advise

2015-09-24 Thread Yehonathan Sharvit
My app is an hybrid app combining *angular* and *om*. (old parts of the app in angular, new parts in om) My concerns are: 1. big app is a symptom of too much complexity 2. compilation time on deployment is very long 3. compilation time during development is too long Any idea how could I

[ClojureScript] Easiest way to compile cljs live

2015-09-10 Thread Yehonathan Sharvit
What's the easiest way to compile cljs live. I'm looking for a webpage or a cli utils that will be easy to use. Currently, I'm using http://swannodette.github.io/2015/07/29/clojurescript-17/ But it's not so convenient -- Note that posts from new members are moderated - please be patient with

[ClojureScript] Re: Easiest way to compile cljs live

2015-09-10 Thread Yehonathan Sharvit
On Thursday, 10 September 2015 12:07:21 UTC+3, Yehonathan Sharvit wrote: > What's the easiest way to compile cljs live. > I'm looking for a webpage or a cli utils that will be easy to use. > > Currently, I'm using http://swannodette.github.io/2015/07/29/clojurescript-17/ >

Re: [ClojureScript] Easiest way to compile cljs live

2015-09-10 Thread Yehonathan Sharvit
On Thursday, 10 September 2015 15:52:37 UTC+3, Mike Fikes wrote: > Yehonathan, > > > Any ClojureScript REPL derived from the shipping REPLs is capable of showing > compiled JS for a form via the :repl-verbose option. > > > See > > >  

Re: [ClojureScript] Extending protocol to an existing JavaScript type

2015-09-06 Thread Yehonathan Sharvit
On Friday, 4 September 2015 20:42:46 UTC+3, Scott Nelson wrote: > OK, thanks. Great documentation by the way. Definitely going to refer to > this from now on. Francis, Do you have an ide yhy the implementation of `extend-type` for: 1. js types modifies the js type itself 2. while for cljs

[ClojureScript] compilation warning when calling satisfies? inside a go block

2015-04-21 Thread Yehonathan Sharvit
This piece of code is causing the following compilation warning: (defprotocol a) (defrecord b []) (go (satisfies? a (b.))) WARNING: Use of undeclared Var cljs-explore.me/bit__4884__auto__ at line 12 src/cljs_explore/me.cljs -- Note that posts from new members are moderated - please be

Re: [ClojureScript] compilation warning when calling satisfies? inside a go block

2015-04-21 Thread Yehonathan Sharvit
I’ve opened a bug: http://dev.clojure.org/jira/browse/ASYNC-121 On Tue, Apr 21, 2015 at 1:02 PM, David Nolen dnolen.li...@gmail.com wrote: File a bug with core.async, thanks. David On Tuesday, April 21, 2015, Yehonathan Sharvit vie...@gmail.com wrote: This piece of code is causing

[ClojureScript] INTERNAL COMPILER ERROR with 0.0-3126 advanced compilation

2015-03-25 Thread Yehonathan Sharvit
Applying optimizations :advanced Compiling public/clojurescript/prod/main.min.js failed. java.lang.RuntimeException: INTERNAL COMPILER ERROR. Please report this problem. null Node(BLOCK): /controller_run_test.js:643:80 return (function $test$controller_run_test$on_scope_render_change($scope,_){

Re: [ClojureScript] INTERNAL COMPILER ERROR with 0.0-3126 advanced compilation

2015-03-25 Thread Yehonathan Sharvit
It didn't happen in earlier versions of cljs. On Wed, Mar 25, 2015 at 7:30 PM, David Nolen dnolen.li...@gmail.com wrote: Looks like a Closure Compiler issue, you probably need to report this elsewhere. On Wednesday, March 25, 2015, Yehonathan Sharvit vie...@gmail.com wrote: Applying

[ClojureScript] [OM] om/update! vs. reset!

2015-03-18 Thread Yehonathan Sharvit
In Om, what is the advantage of calling om/update! instead of reset! Same question for om/transact! and swap! Is it only the stuff with korks and tag or is there also perfomance or logical differences? -- Note that posts from new members are moderated - please be patient with your first post.

[ClojureScript] cljs.test code coverage

2015-02-12 Thread Yehonathan Sharvit
Is there a tool for code coverage for cljs.test? -- Note that posts from new members are moderated - please be patient with your first post. --- You received this message because you are subscribed to the Google Groups ClojureScript group. To unsubscribe from this group and stop receiving

[ClojureScript] Re: Using `not` for keywords

2015-01-15 Thread Yehonathan Sharvit
Because in my app , it is clearer from a semantic point of view, it is clearer as the value stands for a question asked to the user. -- Note that posts from new members are moderated - please be patient with your first post. --- You received this message because you are subscribed to the

[ClojureScript] Using `not` for keywords

2015-01-14 Thread Yehonathan Sharvit
In my app, I am using :yes and :no sometimes instead of true and false. I’d like to know what is the best way to extends the `not` function to be able to handle :yes and :no properly. I was expecting some kind of Boolean protocol but I wasn’t able to find it. I could write this: (defn not

Re: [ClojureScript] Re: ANN: ClojureScript 0.0-2496, cljs.test - a clojure.test port

2014-12-31 Thread Yehonathan Sharvit
, and we already have a JIRA ticket for this. When it is implemented it will trigger all dependent namespaces to recompile. David On Tue, Dec 30, 2014 at 4:27 AM, Yehonathan Sharvit vie...@gmail.com wrote: I have played with the tutorial provided here: http://keeds.github.io/clojurescript/2014

Re: [ClojureScript] Re: ANN: ClojureScript 0.0-2496, cljs.test - a clojure.test port

2014-12-30 Thread Yehonathan Sharvit
Nolen wrote: Time between releases are pretty variable though they tend to be pretty frequent around new features like cljs.test as issues need to be ironed out. I'll probably cut another release on Friday. David On Wed, Dec 24, 2014 at 1:32 PM, Yehonathan Sharvit vie...@gmail.com wrote

Re: [ClojureScript] Re: How to catch exceptions that occur inside a go block

2014-12-25 Thread Yehonathan Sharvit
I like it Elyahou. Thanks -- Note that posts from new members are moderated - please be patient with your first post. --- You received this message because you are subscribed to the Google Groups ClojureScript group. To unsubscribe from this group and stop receiving emails from it, send an

[ClojureScript] Re: Getting started with cljs.test

2014-12-25 Thread Yehonathan Sharvit
Hello Andrew, I'd like to be able to run my cljs test on a continuous integration server. For that purpose. I need to get a proper exit code from lein cljsbuild once test With your tutorial, lein cljsbuild once test always return 0. Is there a way to make the build fail when the tests fail?

Re: [ClojureScript] Re: ANN: ClojureScript 0.0-2496, cljs.test - a clojure.test port

2014-12-24 Thread Yehonathan Sharvit
PM UTC-8, Yehonathan Sharvit wrote: What is the gap between clojure.test and cljs.test? For exmaple: is the `are` macro implemented in cljs.test? On Wednesday, 17 December 2014 23:54:09 UTC+2, David Nolen wrote: ClojureScript, the Clojure compiler that emits JavaScript source code

Re: [ClojureScript] Re: ANN: ClojureScript 0.0-2496, cljs.test - a clojure.test port

2014-12-24 Thread Yehonathan Sharvit
is correct. David On Wed, Dec 24, 2014 at 1:13 PM, Yehonathan Sharvit vie...@gmail.com wrote: What about the 'are' macro? On Wed, Dec 24, 2014 at 7:38 PM, Russell Mull russell.m...@gmail.com wrote: Things that aren't in cljs.test: with-test run-tests can take a custom

[ClojureScript] Re: ANN: ClojureScript 0.0-2496, cljs.test - a clojure.test port

2014-12-23 Thread Yehonathan Sharvit
What is the gap between clojure.test and cljs.test? For exmaple: is the `are` macro implemented in cljs.test? On Wednesday, 17 December 2014 23:54:09 UTC+2, David Nolen wrote: ClojureScript, the Clojure compiler that emits JavaScript source code. README and source code:

Re: [ClojureScript] Bundling JavaScript library with CLJS library

2014-12-21 Thread Yehonathan Sharvit
On 28/11/2014, at 7:16 am, Yehonathan Sharvit vie...@gmail.com wrote: Chas, Is there a way to include a  external javascript file that doesn't support advanced mode compilation? -- Note that posts from new members are moderated - please be patient with your first post

[ClojureScript] Re: ANN: ClojureScript 0.0-2496, cljs.test - a clojure.test port

2014-12-21 Thread Yehonathan Sharvit
Now that var is implemented. Could we expect the support of private functions in cljs? On Wednesday, 17 December 2014 23:54:09 UTC+2, David Nolen wrote: ClojureScript, the Clojure compiler that emits JavaScript source code. README and source code: https://github.com/clojure/clojurescript

Re: [ClojureScript] Re: ANN: core.match 0.3.0-alpha1, enhancements breaking changes

2014-12-16 Thread Yehonathan Sharvit
core.async. David On Tue, Dec 16, 2014 at 1:56 AM, Yehonathan Sharvit vie...@gmail.com wrote: Where in JIRA please? On Sun, Dec 14, 2014 at 12:53 AM, David Nolen dnolen.li...@gmail.com wrote: The issues are outlined in JIRA if you are curious. On Saturday, December 13, 2014

Re: [ClojureScript] Re: ANN: core.match 0.3.0-alpha1, enhancements breaking changes

2014-12-15 Thread Yehonathan Sharvit
Where in JIRA please? On Sun, Dec 14, 2014 at 12:53 AM, David Nolen dnolen.li...@gmail.com wrote: The issues are outlined in JIRA if you are curious. On Saturday, December 13, 2014, Yehonathan Sharvit vie...@gmail.com wrote: What do you mean by “more sophisticated”? Why my piece of code

[ClojureScript] Re: ANN: core.match 0.3.0-alpha1, enhancements breaking changes

2014-12-13 Thread Yehonathan Sharvit
On Saturday, 13 December 2014 15:14:37 UTC+2, David Nolen wrote: Yet another quick release - core.match 0.3.0-alpha4. The only change is fixing a regression around the test sharing of literal patterns. On Fri, Dec 12, 2014 at 12:54 PM, David Nolen dnolen.li...@gmail.com wrote: core.match,

[ClojureScript] Re: [ANN] Fence v0.2.0 - effortless way to avoid manual extern files

2014-12-11 Thread Yehonathan Sharvit
On Thursday, 11 December 2014 12:11:34 UTC+2, p...@banphim.net wrote: This version comes with a `+++` macro that will transform all children interop forms to extern-less equivalent. https://github.com/myguidingstar/fence Hopefully it will save people even more extra keystrokes than

Re: [ClojureScript] [ANN] shin — ClojureScript implementation in Ruby minus the JVM Google Closure parts

2014-12-03 Thread Yehonathan Sharvit
Could you please share an example of an integration of cljs and rails? On Wednesday, 3 December 2014 00:50:57 UTC+2, Thomas Heller wrote: Hey, good luck with your efforts. It seems to be that is was motivated by alot of frustration due to lein-cljsbuild and Google Closure. Most of the

Re: [ClojureScript] Bundling JavaScript library with CLJS library

2014-11-27 Thread Yehonathan Sharvit
Chas, Is there a way to include a external javascript file that doesn't support advanced mode compilation? -- Note that posts from new members are moderated - please be patient with your first post. --- You received this message because you are subscribed to the Google Groups

[ClojureScript] Re: [ANN] clairvoyant 0.0-43-ga703f4e

2014-11-23 Thread Yehonathan Sharvit
: On Monday, November 10, 2014 5:43:50 AM UTC-8, Yehonathan Sharvit wrote: Clairvoyant is really great Joel! I'd like to use the trace-forms inside my project. My thought is to have a macro named: dbgfn that will replace defn in the places where I need to investigate my function calls

Re: [ClojureScript] Re: [ANN] clairvoyant 0.0-43-ga703f4e

2014-11-20 Thread Yehonathan Sharvit
)) (add 1 2) ...or this: (ns x (:require [utils :as u :include-macros true])) (u/dbgfn add [a b] (+ a b)) (add 1 2) HTH! -- Henrik On Tue, Nov 18, 2014 at 9:56 PM, Yehonathan Sharvit vie...@gmail.com wrote: Maybe someone could help me on this. It’s a macro related issue. I appreciate

Re: [ClojureScript] Re: [ANN] clairvoyant 0.0-43-ga703f4e

2014-11-20 Thread Yehonathan Sharvit
it. -- Henrik On Thu, Nov 20, 2014 at 11:20 AM, Yehonathan Sharvit vie...@gmail.com wrote: It means that when in namespace 'my-space', I use a macro 'my-macro' that uses a cljs namespace 'my-ns' , I have to do: (require my-ns) inside 'my-space'. It’s a little bit cumbersome

Re: [ClojureScript] Re: Enforce a source file to be compiled first

2014-11-11 Thread Yehonathan Sharvit
, Yehonathan Sharvit wrote: In my project I have a file: init.cljs with initialization code. For instance: (enable-console-print!) (extend-type js/RegExp ;; allow regexp to be called https://gist.github.com/alandipert/2346460 IFn (-invoke ([this s] (re-matches this s What

[ClojureScript] Re: [ANN] clairvoyant 0.0-43-ga703f4e

2014-11-10 Thread Yehonathan Sharvit
Clairvoyant is really great Joel! I'd like to use the trace-forms inside my project. My thought is to have a macro named: dbgfn that will replace defn in the places where I need to investigate my function calls. Like this: (defmacro dbgfn[ args] `(trace-forms {:tracer

[ClojureScript] Enforce a source file to be compiled first

2014-11-10 Thread Yehonathan Sharvit
In my project I have a file: init.cljs with initialization code. For instance: (enable-console-print!) (extend-type js/RegExp ;; allow regexp to be called https://gist.github.com/alandipert/2346460 IFn (-invoke ([this s] (re-matches this s What is the best way to make sure

[ClojureScript] Re: Improving ClojureScript eval on Light Table

2014-11-09 Thread Yehonathan Sharvit
On Friday, 7 November 2014 15:58:43 UTC+2, Rory Douglas wrote: I'd love it if external browser connection could automatically update the websocket port in my index.html so I don't have to. Or perhaps manage the port lifecycle and assign a stable port per project. I personally really like

[ClojureScript] Re: Writing Clojurescript with Angular

2014-10-20 Thread Yehonathan Sharvit
On Sunday, 19 October 2014 19:25:10 UTC+3, Rory Douglas wrote: I'm not using this, but I'd be interested to know if you're using Gyr or just direct JS interop? I am using Gyr and it is great for: 1. macros for controller/service... definition 2. accessing js nested structure 3. calling js

Re: [ClojureScript] Re: Writing Clojurescript with Angular

2014-10-20 Thread Yehonathan Sharvit
or may not be 'easier', but it's potentially simpler. On Mon, Oct 20, 2014 at 10:47 AM, Yehonathan Sharvit vie...@gmail.com wrote: Could you please elaborate about how 'specify' is helpful in the angular + cljs context? On Sunday, 19 October 2014 23:50:10 UTC+3, Gary Trakhman wrote: Now cljs

[ClojureScript] Ecmascript6 is a threat?

2014-10-19 Thread Yehonathan Sharvit
Do you guys think that Ecmascript6 is a threat to clojurescript? -- Note that posts from new members are moderated - please be patient with your first post. --- You received this message because you are subscribed to the Google Groups ClojureScript group. To unsubscribe from this group and

[ClojureScript] Re: 2014 State of Clojure ClojureScript Survey ends Oct 17th

2014-10-19 Thread Yehonathan Sharvit
On Tuesday, 14 October 2014 16:21:13 UTC+3, Alex Miller wrote: Just a reminder that this Friday is the last day to complete the 2014 State of Clojure ClojureScript surveys: http://blog.cognitect.com/blog/2014/10/3/2014-state-of-clojure-clojurescript-survey So far 1110 people have

[ClojureScript] Writing Clojurescript with Angular

2014-10-19 Thread Yehonathan Sharvit
Hello, I am pushing very strong clojurescript in my company. Currently we use cljs + angular. I am curious to know how many people use this stack and do you have any recommendation? Thanks. -- Note that posts from new members are moderated - please be patient with your first post. ---

[ClojureScript] Re: accessing cljs code from inside a macro

2014-08-31 Thread Yehonathan Sharvit
) What is the best way to access my-cljs/foo from inside the macro? On Saturday, 30 August 2014 20:33:50 UTC+3, Joel Holdbrooks wrote: On Monday, August 25, 2014 1:15:51 PM UTC-7, Yehonathan Sharvit wrote: I would like to write a macro that calls a cljs function. The problem is that the macro

[ClojureScript] accessing cljs code from inside a macro

2014-08-25 Thread Yehonathan Sharvit
I would like to write a macro that calls a cljs function. The problem is that the macro is defined inside a clj file and when I require the namespace that contains the cljs code I receive the following compilation error: Caused by: java.io.FileNotFoundException: Could not locate

Re: [ClojureScript] accessing cljs code from inside a macro

2014-08-25 Thread Yehonathan Sharvit
/async/macros.clj?MobileOptOut=1#L16 On Mon, Aug 25, 2014 at 4:15 PM, Yehonathan Sharvit vie...@gmail.com wrote: I would like to write a macro that calls a cljs function. The problem is that the macro is defined inside a clj file and when I require the namespace that contains the cljs code I

[ClojureScript] Re: Exception while inside core.async go block

2014-08-24 Thread Yehonathan Sharvit
I have tested your code and I saw that an exception was thrown in the the browser console. On Sunday, 16 February 2014 04:27:06 UTC+2, AN wrote: I recently encountered an issue with exceptions being thrown inside a core.async go block. The following code does not result in any sort of an

[ClojureScript] How to catch exceptions that occur inside a go block

2014-08-24 Thread Yehonathan Sharvit
I would like to catch exceptions that occur inside a go block. I need to catch the exceptions from outside the go block. I tried to write this piece of code but it didn't work. The exception was not caught. (try (go (throw (js/Error.My Exception in go block))) (catch js/Object e

Re: [ClojureScript] How to insert a comment in the generated javascript file?

2014-08-24 Thread Yehonathan Sharvit
(where resources is in the same directory as project.clj) and I use preamble like this: :compiler { :preamble [assets/js/myfile.js] ; other compiler options } On 6 August 2014 11:56, Yehonathan Sharvit vie...@gmail.com wrote: I am not able to make it work. Where should I put the file

[ClojureScript] macro to automatically catch exceptions

2014-08-17 Thread Yehonathan Sharvit
I am trying to write a macro deftry that defines a function enveloped in a try/catch statement that will sends the error to Honeybadger. Everything works fine except the fact that I don't know how to pass a js object to the notify function of Honeybadger. It seems that I cannot call clj-js from

Re: [ClojureScript] How to insert a comment in the generated javascript file?

2014-08-06 Thread Yehonathan Sharvit
I am not able to make it work. Where should I put the file? In the same folder as project.clj? On Wed, Jul 30, 2014 at 6:54 PM, Daniel Kersten dkers...@gmail.com wrote: You could use :preamble to prepend a file to the generated output. On 30 July 2014 15:37, Yehonathan Sharvit vie

[ClojureScript] How to insert a comment in the generated javascript file?

2014-07-30 Thread Yehonathan Sharvit
How to insert a comment in the generated javascript file? 1. In simple compilation mode 2. In advanced compilation mode -- Note that posts from new members are moderated - please be patient with your first post. --- You received this message because you are subscribed to the Google Groups

Re: [ClojureScript] Re: ClojureScript Clojure 1.6.0

2014-07-10 Thread Yehonathan Sharvit
: :closure-warnings {:check-useless-code :off} should do the trick in your build settings. David On Sun, Jul 6, 2014 at 11:18 PM, Yehonathan Sharvit vie...@gmail.com wrote: David, This compiltaion issue is still not solved. It prevents from me to upgrade to the latest clojurescript

Re: [ClojureScript] Detecting ClojureScript compilation in macros

2014-06-09 Thread Yehonathan Sharvit
Why clix is a workaround and not considered as the best solution? -- Note that posts from new members are moderated - please be patient with your first post. --- You received this message because you are subscribed to the Google Groups ClojureScript group. To unsubscribe from this group and

[ClojureScript] Re: ClojureScript Clojure 1.6.0

2014-06-09 Thread Yehonathan Sharvit
I have compilation warnings related to core.async. Here is the log: Compiling resources/public/js/main.js from [src/cljs]... Jun 10, 2014 7:49:49 AM com.google.javascript.jscomp.LoggerErrorManager println WARNING: /Users/viebel/libs/klozzer/target/cljsbuild-compiler-0/cljs/core/async.js:127:

[ClojureScript] where is the format function

2014-04-30 Thread Yehonathan Sharvit
It seems that “format” has been removed from cljs. It was added 2 years ago in https://github.com/clojure/clojurescript/commit/8f518760a3df8b351208e97bb70270856623bb0a Also, goog.string.format is not available any more. My question is: what is the best way to add leading zeros in cljs? -- Note

[ClojureScript] Clojurescript + rails on heroku

2014-04-11 Thread Yehonathan Sharvit
What is the best way to deploy my clojurescript + rails app on heroku? My app is detected as a rails app by heroku and therefore Lein is not available at deploy time to compile my cljs files.  -- Note that posts from new members are moderated - please be patient with your first post. --- You

Re: [ClojureScript] Javascript arrays

2014-04-08 Thread Yehonathan Sharvit
Also, in Clojure on the JVM get works with Java Maps, while in Clojurescript get doesn't work with js object. Is there a reason for that? On Mon, Apr 7, 2014 at 11:00 PM, Yehonathan Sharvit vie...@gmail.comwrote: What about js *typed arrays*? Why *(array? (js/Float32Array. 3))* is false

Re: [ClojureScript] fast reduce

2014-04-08 Thread Yehonathan Sharvit
I have discovered that *areduce* is also very fast: (areduce a i res 0 (+ res (aget a i))) I feel that it preserves the functional programming spirit. Any comment on that, David? On Tue, Apr 8, 2014 at 9:44 AM, Yehonathan Sharvit vie...@gmail.com wrote: Thanks David! I see

Re: [ClojureScript] Can't get AngularJS call working...

2014-04-06 Thread Yehonathan Sharvit
On Sunday, 6 April 2014 20:14:18 UTC+3, Kevin Lynagh wrote: Angular uses some tricks for its dependency injection that can break under some minifications: http://stackoverflow.com/questions/18782324/angularjs-minify-best-practice You can tidy that syntax up in cljs via a macro:

[ClojureScript] Javascript arrays

2014-04-06 Thread Yehonathan Sharvit
I was surprised when I discovered that the following code worked: (some #{2} (clj-js [1 2])) (count (clj-js [1 2])) My question is: Could javascript arrays be safely passed to core functions that received a vector? -- Note that posts from new members are moderated - please be patient with