My first web development project.

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

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 (!) and it's my first web project.

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.

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.

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.

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.

Re: TryClojure

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

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.