TryClojure

My first web development project.

Page 1 of 1

11 Replies - 1539 Views - Last Post: 01 December 2010 - 04:59 AM

#1 Raynes  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 611
  • View blog
  • Posts: 2,815
  • Joined: 05-January 09

TryClojure

Posted 09 May 2010 - 10:30 PM

Over the last couple of days, I've been working on a new (and my first) web development project. It's a web application reminiscent of the TryRuby/Haskell sites, only without all the pretty Javascript. It works just like a normal REPL, only sandboxed.

A friend (and fellow clj-sandbox author) gave me access to his remote server a while back, and he has given me a subdomain to deploy TryClojure on, so you guys can play with it. You can check it out at tryclj.licenser.net.

If you have any ideas for colors, toss them at me. I've been fighting with myself over colors all night.

The source is here: http://github.com/Raynes/tryclojure, and it's written in 102 lines of Clojure, including some inline JS and not including the CSS file. I'm quite proud of it, because it actually works (:D!) and it's my first web project.

Enjoy.

Is This A Good Question/Topic? 1
  • +

Replies To: TryClojure

#2 programble  Icon User is offline

  • (cons :dic :head)

Reputation: 49
  • View blog
  • Posts: 1,315
  • Joined: 21-February 09

Re: TryClojure

Posted 10 May 2010 - 01:29 PM

It's great how everyone seems to completely ignore your projects.

*tumbleweed*
Was This Post Helpful? 0
  • +
  • -

#3 Raynes  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 611
  • View blog
  • Posts: 2,815
  • Joined: 05-January 09

Re: TryClojure

Posted 10 May 2010 - 02:04 PM

Not everybody. The actual Clojure community was pretty excited about this.

I don't expect much. I just post these here to show that I actually do code. :P
Was This Post Helpful? 0
  • +
  • -

#4 Raynes  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 611
  • View blog
  • Posts: 2,815
  • Joined: 05-January 09

Re: TryClojure

Posted 10 May 2010 - 09:20 PM

Just thought I would note that I just added syntax highlighting to http://tryclj.licenser.net/, powered by SyntaxHighlighter.
Was This Post Helpful? 0
  • +
  • -

#5 Skaggles  Icon User is offline

  • THE PEN IS MIGHTIER
  • member icon





Reputation: 251
  • View blog
  • Posts: 640
  • Joined: 01-March 09

Re: TryClojure

Posted 10 May 2010 - 09:29 PM

I like it, but I'm also use to a more real-time web console like try ruby!. However, really enjoyed messing with the site. Never used Clojure before and I had to look up some beginner tutorials, but perhaps that was the plan.

:punk:

This post has been edited by Skaggles: 10 May 2010 - 09:30 PM

Was This Post Helpful? 0
  • +
  • -

#6 Raynes  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 611
  • View blog
  • Posts: 2,815
  • Joined: 05-January 09

Re: TryClojure

Posted 10 May 2010 - 09:54 PM

There is a link to a tutorial on the left part of the page.

As for the lack of a real-time console like TryRuby and TryHaskell has, I kind of did that on purpose. I wanted this one to be generally pure-clojure with just a bit of Javascript here and there. Also, since this was my first web project, I wanted to do it all on my own, and I don't know Javascript right now (and a real-time console is a pretty complex work of art), so I did it like this.

It's pretty fast though, and the only difference between it and a real-time console is the fact that it refreshes the page every time you enter code. I'm considering learning Javascript, because it's pretty crucial, and I hope to do more Clojure web work in the future. Once I do, I might write my own real-time console, if people dislike what I'm doing now enough. :P

A friend is actually working on a TryClojure himself, based on mine, that uses the Javascript that TryHaskell uses (which is pretty much the same as the Javascript console that TryRuby uses). I might steal his stolen Javascript for mine sometime, and make it Javascript-optional. I like the mostly-HTML-based stuff because it works really well on my shitty cellphone. :P

I'm happy you like it, and if you're interested in Clojure, I just wrote this earlier today: http://www.dreaminco...al-programming/

I might write a Clojure tutorial for right here on DiC soon, since a couple of people have asked me to.

EDIT: After thinking, I can probably do something with an iframe to keep from having to reload the whole page.

This post has been edited by Raynes: 10 May 2010 - 10:01 PM

Was This Post Helpful? 0
  • +
  • -

#7 Raynes  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 611
  • View blog
  • Posts: 2,815
  • Joined: 05-January 09

Re: TryClojure

Posted 11 May 2010 - 03:58 PM

The site is down for a few. I'm being forced to disable anything def*, because of a general memory problem we're ('we're' being me and a friend, Heinz). We're working on a way to limit memory usage in a sandbox, because it's a general problem, we intend to put it in the sandbox library itself.

UPDATE: Site is back up. def* stuff has been disabled until this situation is remedied, and automatic scrolling to the bottom of the output div isn't working quite right since I added syntax highlighting. Working on that one as well.

This post has been edited by Raynes: 11 May 2010 - 08:26 PM

Was This Post Helpful? 0
  • +
  • -

#8 Raynes  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 611
  • View blog
  • Posts: 2,815
  • Joined: 05-January 09

Re: TryClojure

Posted 14 May 2010 - 08:07 AM

The site has been completely redesigned with the help of a much more experienced friend.

Besides the new design, I'm also using Chris Done's jquery-console JQuery plugin, which is what Chris used on tryhaskell.

Due to some bugs in clj-sandbox that will be fixed as soon as possible, the REPL isn't quite as functional as a typical REPL. It will be once the bugs are fixed though.

Same place as always: http://tryclj.licenser.net/

This post has been edited by Raynes: 14 May 2010 - 08:27 PM

Was This Post Helpful? 2
  • +
  • -

#9 skyhawk133  Icon User is offline

  • Head DIC Head
  • member icon

Reputation: 1876
  • View blog
  • Posts: 20,284
  • Joined: 17-March 01

Re: TryClojure

Posted 14 May 2010 - 08:35 AM

Very cool man. Nice project!
Was This Post Helpful? 0
  • +
  • -

#10 Raynes  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 611
  • View blog
  • Posts: 2,815
  • Joined: 05-January 09

Re: TryClojure

Posted 18 May 2010 - 05:27 PM

Thanks!

I just deployed a new release. This one enables def, and also has a brief, and totally incomplete first-cut tutorial that I'll start more serious work on tomorrow. This thing is really turning out.

http://www.try-clojure.org
Was This Post Helpful? 0
  • +
  • -

#11 Raynes  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 611
  • View blog
  • Posts: 2,815
  • Joined: 05-January 09

Re: TryClojure

Posted 07 June 2010 - 01:01 AM

Just a general update.


Error handling and such have been greatly improved. The tutorial has been rather stagnant in progress lately, because I've been busy with other things. That will change soon.


A person from the Clojure community liked TryClojure enough that he took the time to make a Google Chrome extension that uses it to launch an REPL in your browser without even bothering to visit the site. It's pretty awesome: https://chrome.googl...anopflcfdaennle
Was This Post Helpful? 0
  • +
  • -

#12 Raynes  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 611
  • View blog
  • Posts: 2,815
  • Joined: 05-January 09

Re: TryClojure

Posted 01 December 2010 - 04:59 AM

Update:

Over time, the development of Try Clojure stagnated. It remained that way for several months. Very recently, I posted a call to action on my blog to try to get contributors with skill sets that could complement mine.

The biggest problems were: I'm not a web designer, and I'm hardly a web developer. A lot of the site is powered by Javascript and I'm just not savvy enough in that area to really make any dents in what need[s|ed] to be done.

For the most part, the call to action has been successful. The website has been completely redesigned by a contributor to be more colorful and look more like the other try<language> sites (I model mine after http://tryhaskell.org). Check it out.

Besides that, I've also developed a brand new sandboxing library called clojail, and Try Clojure's sandbox is much improved.

There is also a guy working on interactive Javascript tutorial, much like the one you can see at http://tryhaskell.org No estimation as to when that will be around.

In any case, enjoy.
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1