{jaggery.js}

Is something I’ve been working on at wso2 for sometime, if you are following me I have tweeted the updates, releases etc. Jaggery went live with its fifth milestone, few weeks ago at jaggeryjs.org, its still young and has alot to improve.

Explaining a little bit about jaggery; Its NOT an alternative to node, its simply a toolkit to easily compose webapps and apis. Its a completely javascript way of writing all parts of the web application, and communicate throughout in json. Jaggery has out of the box features to create RESTfull applications, and its one of it’s value propositions. Jaggery can be easily extended via modules which can be written in javascript or java for that matter.

A very simple page that prints out some request properties in jaggery looks like,

<html>
   <body>
      <p>
      <%
          print("Method : " + request.getMethod() + "<br/>");
          print("Protocol : " + request.getProtocol() + "<br/>");
          print("User-Agent : " + request.getHeader("User-Agent"));
      %>
      </p>
   </body>
</html>

Jaggery docs site also provide a tool for you to try out some code and play around. So you can simply copy the above code and paste in jaggery try-it

I recently did a webinar on jaggery that explains the simple case, over looking its API and samples. Below is the recording hope it’ll help.

Advertisement