REBOL Technologies

On JSON and REBOL

Carl Sassenrath, CTO
REBOL Technologies
13-Dec-2012 6:39 GMT

Article #0522
Main page || Index || Prior Article [0521] || Next Article [0523] || 13 Comments || Send feedback

Flipping through some Github blog pages, I came across the Github API in JSON. For example: https://status.github.com/api

It's ironic. Every time I run across JSON examples, I see REBOL without the elegance. The two languages are related of course. REBOL strongly influenced the design of JSON.

Consider the above github API example...

In JSON:

[
 {
   "status": "good",
   "body": "Battlestation fully operational",
   "created_on": "2012-12-07T18:11:55Z"
 },
 {
   "status": "minor",
   "body": "Almost done reticulating splines",
   "created_on": "2012-12-05T12:08:33Z"
 }
]

In REBOL:

[
 [
   status: good
   body: "Battlestation fully operational"
   created_on: 2012-12-07/18:11:55
 ]
 [
   status: minor
   body: "Almost done reticulating splines"
   created_on: 2012-12-05/12:08:33
 ]
]

It's clear, isn't it?

Expression of information is not just about structure. It's not just about name-value pairs. It's also about the datatypes as values and the ability to handle and manipulate those too.

Meaning isn't just in strings, it's in the full expression itself. A holistic representation. The REBOL form includes set-words, words, strings, dates, and blocks - lexically cleaner, less syntax, as well.

Unfortunately, many programmers don't think outside of the box. They're stuck in a narrow world of strings and unnecessary punctuation.

The mind is naturally capable and comfortable with so much more. Use it.

13 Comments

Updated 4-Dec-2024   -   Copyright Carl Sassenrath   -   WWW.REBOL.COM   -   Edit   -   Blogger Source Code