{"_id":"seriousjs","_rev":"27-93059c78ab96287d7077c3e563971773","name":"seriousjs","description":"An improved javascript syntax with tools for developing large-scale applications and websites","dist-tags":{"latest":"0.1.9"},"versions":{"0.1.0":{"name":"seriousjs","preferGlobal":true,"version":"0.1.0","author":{"name":"Walt Woods","email":"woodswalben@gmail.com"},"description":"An improved javascript syntax with tools for developing large-scale applications and websites","bin":{"seriousjs":"./bin/seriousjs"},"scripts":{"postinstall":"./bin/seriousjs --compile-only"},"main":"./index.js","dependencies":{"commander":">=0.0.0"},"devDependencies":{"mocha":">=1.8","requirejs":"2.1.2"},"repository":{"type":"git","url":"git://github.com/wwoods/seriousjs.git"},"license":"MIT","engines":{"node":">=0.7"},"_id":"seriousjs@0.1.0","dist":{"shasum":"2d75d0a198666c03ead0d3015e2365a36cd7baba","tarball":"https://registry.npmjs.org/seriousjs/-/seriousjs-0.1.0.tgz","integrity":"sha512-P0NvHbvcebwNy5FyVeaE4qJYc+9kAXmcCJV7gxtZzfYSqYTT/TjV2hC79Vb/tVmzhj6fyed8+GrTslhCjfSj8Q==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCJhEKPOG68oYyaMMWsEyR4mFU7rria1eAwtb18gzuBkwIgaO6dzVvkbWb69NG3b5FxDR6qyVb9+H+YBb2FLXX6//Q="}]},"_npmVersion":"1.1.62","_npmUser":{"name":"wwoods","email":"woodswalben@gmail.com"},"maintainers":[{"name":"wwoods","email":"woodswalben@gmail.com"}],"directories":{}},"0.1.1":{"name":"seriousjs","preferGlobal":true,"version":"0.1.1","author":{"name":"Walt Woods","email":"woodswalben@gmail.com"},"description":"An improved javascript syntax with tools for developing large-scale applications and websites","bin":{"seriousjs":"./bin/seriousjs"},"scripts":{"postinstall":"./bin/seriousjs --compile-only"},"main":"./index.js","dependencies":{"commander":">=0.0.0"},"devDependencies":{"mocha":">=1.8","requirejs":"2.1.2"},"repository":{"type":"git","url":"git://github.com/wwoods/seriousjs.git"},"license":"MIT","engines":{"node":">=0.7"},"_id":"seriousjs@0.1.1","dist":{"shasum":"87e07c197ad7f226504965051a3cee0c2a0d04a6","tarball":"https://registry.npmjs.org/seriousjs/-/seriousjs-0.1.1.tgz","integrity":"sha512-gtBshiFRQdciKfh5ZlOsylZAy1juguFRGtsWvFdMNXiuy7Z+aVkhEVS00f983CGUtPwKAiIrziWcInu1EPF7bQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCqenVqEpsq0zC7GFSdqLbYAorgKaERQ3z0EyBFAUlI2wIhAJmJ2pQoh/XzPdf5XvLYIAxTyT5X4UAQ6p4eyMdTpaKL"}]},"_npmVersion":"1.1.62","_npmUser":{"name":"wwoods","email":"woodswalben@gmail.com"},"maintainers":[{"name":"wwoods","email":"woodswalben@gmail.com"}],"directories":{}},"0.1.2":{"name":"seriousjs","preferGlobal":true,"version":"0.1.2","author":{"name":"Walt Woods","email":"woodswalben@gmail.com"},"description":"An improved javascript syntax with tools for developing large-scale applications and websites","bin":{"seriousjs":"./bin/seriousjs"},"scripts":{"postinstall":"./bin/seriousjs --compile-only"},"main":"./index.js","dependencies":{"commander":">=0.0.0"},"devDependencies":{"mocha":">=1.8","requirejs":"2.1.2"},"repository":{"type":"git","url":"git://github.com/wwoods/seriousjs.git"},"license":"MIT","engines":{"node":">=0.7"},"_id":"seriousjs@0.1.2","dist":{"shasum":"4f63c4fc3da91649e7c05524e1da4c31113fa46e","tarball":"https://registry.npmjs.org/seriousjs/-/seriousjs-0.1.2.tgz","integrity":"sha512-8TAeBUoq+yaNvJmJ419eaatlecfS1cNWkDgjktVnqouVF4ajbQXKto2m0dAXZvdIn6vwkMDBivFuh66e2H9h5Q==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCICY3dkb5SufhzwVEqzM0xTpoPeU7GTix1TwSMy6pQu7UAiEA8YNBdX0awWPxL3thbpj4T/C/9VVs9mxzt3h9pFjj3PE="}]},"_npmVersion":"1.1.62","_npmUser":{"name":"wwoods","email":"woodswalben@gmail.com"},"maintainers":[{"name":"wwoods","email":"woodswalben@gmail.com"}],"directories":{}},"0.1.3":{"name":"seriousjs","preferGlobal":true,"version":"0.1.3","author":{"name":"Walt Woods","email":"woodswalben@gmail.com"},"description":"An improved javascript syntax with tools for developing large-scale applications and websites","bin":{"seriousjs":"./bin/seriousjs"},"scripts":{"prepublish":"./bin/seriousjs --compile-seriousjs","test":"mocha --compilers sjs:./index test test/slowTests"},"main":"./index.js","dependencies":{"commander":">=0.0.0"},"devDependencies":{"mocha":">=1.8","requirejs":"2.1.2","uglify-js":">=2.0.0"},"repository":{"type":"git","url":"git://github.com/wwoods/seriousjs.git"},"license":"MIT","engines":{"node":">=0.7"},"_id":"seriousjs@0.1.3","dist":{"shasum":"3f17d57ec7baf02b003ecdb9d028673af0b75a54","tarball":"https://registry.npmjs.org/seriousjs/-/seriousjs-0.1.3.tgz","integrity":"sha512-qN1KXkW/4xlM4oBPqNMlXuH0JEjiq1jR5vVVvXuNjR8CVGwWoV6Ra6B/FnVb7dusMTeJx+xj5EfXO18Y/nfhUA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCF6n/GcWJ4r8qWXB0rK+eqjd7HgPW3i4y6H6US8W0viAIgDvPFYF5MIHm1tSZVbak8nyBtNS8QKmorXb3Qz3FvRoU="}]},"_npmVersion":"1.1.62","_npmUser":{"name":"wwoods","email":"woodswalben@gmail.com"},"maintainers":[{"name":"wwoods","email":"woodswalben@gmail.com"}]},"0.1.5":{"name":"seriousjs","preferGlobal":true,"version":"0.1.5","author":{"name":"Walt Woods","email":"woodswalben@gmail.com"},"description":"An improved javascript syntax with tools for developing large-scale applications and websites","bin":{"seriousjs":"./bin/seriousjs"},"scripts":{"prepublish":"./bin/seriousjs compile-seriousjs","test":"mocha --compilers sjs:./index test test/slowTests"},"main":"./index.js","dependencies":{"commander":">=0.0.0"},"devDependencies":{"mocha":">=1.8","requirejs":"2.1.2","uglify-js":">=2.0.0"},"repository":{"type":"git","url":"git://github.com/wwoods/seriousjs.git"},"license":"MIT","engines":{"node":">=0.7"},"_id":"seriousjs@0.1.5","dist":{"shasum":"19ebd106a4f9ecd8077c78e35ad0b58bfe0e1928","tarball":"https://registry.npmjs.org/seriousjs/-/seriousjs-0.1.5.tgz","integrity":"sha512-X+SaQnfPQtINgBXy12y08fEsb3Qpw/YfERH4/PI8lVDlM32xmAABAvFQZac/gkY4q6iACFApLOc46R1o2/CjJQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDM7B5a+Am36pzwxQFozCN31+TwGSK72FqZ5VQIxAH6SgIhAKP1nwWcPTGJJNLdnk0O1FkOOTgcA6Gnr30E9XTcf3Tx"}]},"_npmVersion":"1.1.62","_npmUser":{"name":"wwoods","email":"woodswalben@gmail.com"},"maintainers":[{"name":"wwoods","email":"woodswalben@gmail.com"}]},"0.1.6":{"name":"seriousjs","preferGlobal":true,"version":"0.1.6","author":{"name":"Walt Woods","email":"woodswalben@gmail.com"},"description":"An improved javascript syntax with tools for developing large-scale applications and websites","bin":{"seriousjs":"./bin/seriousjs"},"scripts":{"prepublish":"./bin/seriousjs compile-seriousjs --release","test":"mocha --compilers sjs:./index test test/slowTests"},"main":"./index.js","dependencies":{"commander":">=0.0.0"},"devDependencies":{"mocha":">=1.8","requirejs":"2.1.2","uglify-js":">=2.0.0"},"repository":{"type":"git","url":"git://github.com/wwoods/seriousjs.git"},"license":"MIT","engines":{"node":">=0.7"},"_id":"seriousjs@0.1.6","dist":{"shasum":"731de6d95d3724e675591333e8b5fa68a7f24402","tarball":"https://registry.npmjs.org/seriousjs/-/seriousjs-0.1.6.tgz","integrity":"sha512-YEHOuRJvrfG1oQ0OVuLapA3LvzNcxvCTfKA3mjQps5Q2hloTOgUte5Jw9JNP5zlRnn7UC7vgO2R3jDMb0J3lzA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIAnT96pcOlqkDXZbFXoOciOhv1ZGWzoIkjiPVDDjTqOkAiBFE5pQSmKTyIEw0HuqFNoei6xE02aw/PNDub4Hh3tZzg=="}]},"_npmVersion":"1.1.62","_npmUser":{"name":"wwoods","email":"woodswalben@gmail.com"},"maintainers":[{"name":"wwoods","email":"woodswalben@gmail.com"}]},"0.1.7":{"name":"seriousjs","preferGlobal":true,"version":"0.1.7","author":{"name":"Walt Woods","email":"woodswalben@gmail.com"},"description":"An improved javascript syntax with tools for developing large-scale applications and websites","bin":{"seriousjs":"./bin/seriousjs"},"scripts":{"prepublish":"./bin/seriousjs compile-seriousjs --release","test":"mocha --compilers sjs:./index test test/slowTests"},"main":"./index.js","dependencies":{"commander":">=0.0.0"},"devDependencies":{"mocha":">=1.8","requirejs":"2.1.2","uglify-js":">=2.0.0"},"repository":{"type":"git","url":"git://github.com/wwoods/seriousjs.git"},"license":"MIT","engines":{"node":">=0.7"},"_id":"seriousjs@0.1.7","dist":{"shasum":"88fdf60871576d77e973d458968ba5f2544aa22e","tarball":"https://registry.npmjs.org/seriousjs/-/seriousjs-0.1.7.tgz","integrity":"sha512-FNZHoA6qP0RoE+tlu/CQGNIYlsDEoBVp0nIWNIX+QlRsBRnlagL198QXLao0Jb4jsKpB6IX8kStGreXQFZaQyw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDLsodz4yAfx7X0u+PSFWNxNp0JmYv5PdqaeGgAMOppjAIhANPq73yy8T+2cUQI94wNnfnMhHkiJbgBYXWdOwPAzG4L"}]},"_npmVersion":"1.1.62","_npmUser":{"name":"wwoods","email":"woodswalben@gmail.com"},"maintainers":[{"name":"wwoods","email":"woodswalben@gmail.com"}]},"0.1.8":{"name":"seriousjs","preferGlobal":true,"version":"0.1.8","author":{"name":"Walt Woods","email":"woodswalben@gmail.com"},"description":"An improved javascript syntax with tools for developing large-scale applications and websites","bin":{"seriousjs":"./bin/seriousjs"},"scripts":{"prepublish":"./bin/seriousjs compile-seriousjs --release","test":"mocha --compilers sjs:./index test test/slowTests"},"main":"./index.js","dependencies":{"commander":"2.2.x","uglify-js":"2.4.x","source-map":"0.1.x","source-map-support":"0.2.x"},"devDependencies":{"mocha":"1.x","requirejs":"2.1.x"},"repository":{"type":"git","url":"git://github.com/wwoods/seriousjs.git"},"license":"MIT","engines":{"node":">=0.10"},"bugs":{"url":"https://github.com/wwoods/seriousjs/issues"},"homepage":"https://github.com/wwoods/seriousjs","_id":"seriousjs@0.1.8","dist":{"shasum":"c63fe50b424b40a972bab6fef16599c553e2c22a","tarball":"https://registry.npmjs.org/seriousjs/-/seriousjs-0.1.8.tgz","integrity":"sha512-oiFEgHJSqv6iLc09mfuf/ktjWT8wENDO/FOt18WHjsZ8+Mnv3/NYvn5mMrg5c+yLO2hpnIMhTzopq4B0Z321vw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIFNvDDWb5wIQqcd3oX81JWqKeibBDUFosp1D6lJQRvjuAiBh16uP7fRfT5dIXsvQ0KL01s4BKNgSfFLgQBdZ+GYH8g=="}]},"_from":".","_npmVersion":"1.3.14","_npmUser":{"name":"wwoods","email":"woodswalben@gmail.com"},"maintainers":[{"name":"wwoods","email":"woodswalben@gmail.com"}]},"0.1.9":{"name":"seriousjs","preferGlobal":true,"version":"0.1.9","author":{"name":"Walt Woods","email":"woodswalben@gmail.com"},"description":"An improved javascript syntax with tools for developing large-scale applications and websites","bin":{"seriousjs":"./bin/seriousjs"},"scripts":{"prepublish":"./bin/seriousjs compile-seriousjs --release","test":"mocha --compilers sjs:./index test test/slowTests"},"main":"./index.js","dependencies":{"commander":"2.2.x","uglify-js":"2.4.x","source-map":"0.1.x","source-map-support":"0.2.x"},"devDependencies":{"mocha":"1.x","requirejs":"2.1.x"},"repository":{"type":"git","url":"git://github.com/wwoods/seriousjs.git"},"license":"MIT","engines":{"node":">=0.10"},"bugs":{"url":"https://github.com/wwoods/seriousjs/issues"},"homepage":"https://github.com/wwoods/seriousjs","_id":"seriousjs@0.1.9","dist":{"shasum":"d2e43a6697e70d4ef57c41493222147f58b83571","tarball":"https://registry.npmjs.org/seriousjs/-/seriousjs-0.1.9.tgz","integrity":"sha512-l7gc8SU51BdgEt/iqt+jQYK9+Ja6Ubtjf9WhazGdrQxRc6IknT6D8JRzU5xAgVGgj1Rl2CWnFMjmmaYELv2vMg==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIHTlpmbjN1nr8ReDTWuCJwdoIXvff4TPWQ6FNIug46dmAiEA9zBUoysyEUQZUgZovZr14g9Flna8DaQ0DXl4swqV6rE="}]},"_from":".","_npmVersion":"1.4.3","_npmUser":{"name":"wwoods","email":"woodswalben@gmail.com"},"maintainers":[{"name":"wwoods","email":"woodswalben@gmail.com"}]}},"readme":"SeriousJS\n=========\n\nA simple syntax for a complicated world.\n\nThere is an interactive interpreter available at: http://wwoods.github.io/seriousjs/\n\n## Motivation\n\nFeel free to skip to the bottom if you like - but a lot of people will ask\nwhy I bothered implementing a language that follows Coffee-Script 99% of the\ntime.\n\nOk, why re-write Coffee-Script?  My initial motivation was that\nthe coffee-script parser has really weird limitations.  For instance:\n\n    if someLongVariable\n            + someOtherLongVariable == 8\n        doSomething()\n\nWon't compile with Coffee-Script, despite making complete visual sense.  I've\nalso come across the scenario where, after several layers of lambda and\nobject literal nesting, coffee-script broke.  Granted I should have distilled\nthe situation and fixed Coffee-Script's parser, but it was just a frustrating\nexperience.\n\nSince I was just learning PegJS for another project, I thought it would be fun\nto try to make a Coffee-Script parser that didn't have so many bizarre\nlimitations in the syntax.\n\nAs I was looking at Coffee-Script's design choices and my past coffee-script\nprojects, there were some other things that bugged me constantly:\n\n* -> vs => - Why?  I mean, I understand how coffee-script uses them, but if\n  a language introduces a beautiful syntax like @ to mean \"the object that\n  this method is operating on\", why would you confuse the issue with\n  function bindings?  \"@\" should mean \"the closest class object\", and \"this\"\n  should mean the context with which the current method was called.\n\n* Why are there so many aliases for true/false?  It's because it's a\n  scripting language.  I get that.  But for large, maintainable code bases, I\n  don't feel that it's appropriate to have so many ways of saying \"false\" and\n  \"true\".  Feel free to correct me on that one.\n\n* Guess what this code does:\n\n        $('<div>')\n            .bind 'click', -> alert(\"Click!\")\n            .appendTo('body')\n\n  If you guessed \"It sure doesn't append that div to the body!\" you were\n  correct.  Coffee-Script associates the .appendTo with the return value from\n  calling alert(), quite contrary to what the indentation implies.\n\nWhile those aren't huge, they got me thinking.  What are some other ways that\nCoffee-Script could be improved?  Well, how about:\n\n* Support for asynchronous fibers / continuations?  Programming callbacks in\n  an imperative manner rather than a bunch of nested functions\n\n* Tight integration with RequireJS, to provide a uniform, consistent language\n  between NodeJS and the browser, that runs in all environments and\n  \"just works\"\n\n* Doc strings!  One of the best things about Python that really helped it\n  be a great language was doc strings.  An interactive language needs\n  interactive help.  So why not start encouraging them?\n\nAnyway, that's the jist of it.  I'm not expecting people to jump ship on this\none - it started as an educational project but the focus is on production\nquality language constructs.  I mostly just think it's a useful conversation\nstarter.\n\n\n## Basics\n\nSeriousJS is inspired by Coffee-Script, but aimed at making the parsing more\ndependable and providing extensions for a uniform code base across NodeJS and\nbrowser implementations.  Emphasis is on making projects easy to manage and\nlearn.\n\nRemember, there is an interactive interpreter to play with at: http://wwoods.github.io/seriousjs/\n\n\nUsage\n-----\n\nFor a shorthand to run any SeriousJS script in NodeJS, just use:\n\n    seriousjs app.sjs\n\nTo start a new SeriousJS HTTP client/server project with RequireJS set up, run:\n\n    seriousjs create-app [appname]\n\nThis makes a folder named [appname] and sets up a skeleton hierarchy, with an\nexample web server and configuration.  It also comes with a stock .gitignore\nfile, which suffices for simple projects.\n\nTo compile your new application, run:\n\n    seriousjs app.sjs --build\n\nfrom your application directory.  A \"webapp.build\" directory will be created,\nwhich has compiled sources for your client.\n\nTo run the compiled version, run:\n\n    seriousjs app.sjs --built\n\nNote that if you run --built without --build first, a build will be triggered\nanyway.\n\n\nUsage in a browser\n------------------\n\nIf you run seriousjs --compile-only (ran during install anyway), then the file\nlib/seriousjs-embed.js will be generated.  This is a self-contained file that\nmay be used in a browser (or NodeJS, of course).\n\nOr just run \"seriousjs --create-app myapp\" and have a working demonstration.\n\n\nSyntax\n------\n\nFunctions are lambdas:\n\n    (a, b) -> a + b\n\nLong functions can have doc strings:\n\n    (a, b) ->\n        \"\"\"Returns the summation of a and b.\n        \"\"\"\n        return a + b\n\nDict unmapping:\n\n    { a, b } = { a: 8, b: 9 }\n    { a = 8, b } = { b: 9 }\n\n    # < means that the matched dict must contain a subset of the specified\n    # keys.  That is, the first will be OK (b is undefined), but the second\n    # will throw an error (c not allowed)!\n    {< a, b } = { a: 1 }\n    {< a, b } = { a: 1, c: 3 }\n\n    # > means at least the specified keys must be in the matched dict\n    {> a } = { a: 1, b: 2 }\n\n    # = means keys must match exactly\n    {= a, b } = { a: 3, b: 4 }\n\nDict unmapping as lambda arguments:\n\n    { a, b } -> a + b\n    (a, b, {< add = true}) -> add ? a + b : a\n\nClasses and @-binding:\n\n    class Test\n      constructor: (@value = 5) ->\n        return\n\n      inner: () ->\n        console.log @value\n\n      f: (g) ->\n        g(@@inner)\n\n\n    t = Test(42)\n    # This will log 42, which is t.value.  Note that the binding of the\n    # function was preserved when it was referenced with @.\n    # Useful for e.g. callbacks bound to events\n    t.f (method) -> method()\n\n\nChangelog\n---------\n\n### 0.1.9\n* 2014-4-24 - Made create-static template, for sites with no server component.\n  Check if callback is function for async, if it's not, unset it.  Fixed parse\n  error with arguments separated by newlines.\n\n### 0.1.8\n* 2014-4-21 - Updated create-app template.  Added test as a TODO.  Updated\n  version / npm registry with latest changes.\n* 2014-4-3 - Fixed list of lists parsing, async throwing, async catch blocks in\n  a for loop, onAsyncUnhandledError, onAsyncSecondaryError\n\n\nTODO\n----\n\n* i[??] Random choose operator?  Would be handy to have that built in...  Probably should think that one through though.\n\n\n[![Bitdeli Badge](https://d2weczhvl823v0.cloudfront.net/wwoods/seriousjs/trend.png)](https://bitdeli.com/free \"Bitdeli Badge\")\n\n","maintainers":[{"name":"wwoods","email":"woodswalben@gmail.com"}],"time":{"modified":"2022-06-26T17:57:14.022Z","created":"2013-04-19T15:52:42.135Z","0.1.0":"2013-04-19T15:52:45.365Z","0.1.1":"2013-04-19T17:09:38.456Z","0.1.2":"2013-04-20T02:38:26.343Z","0.1.3":"2013-04-20T12:23:21.052Z","0.1.5":"2013-04-23T19:27:26.323Z","0.1.6":"2013-04-30T18:45:44.698Z","0.1.7":"2013-05-10T00:05:24.296Z","0.1.8":"2014-04-22T03:12:12.507Z","0.1.9":"2014-04-25T04:15:25.332Z"},"author":{"name":"Walt Woods","email":"woodswalben@gmail.com"},"repository":{"type":"git","url":"git://github.com/wwoods/seriousjs.git"},"license":"MIT","readmeFilename":"README.md","homepage":"https://github.com/wwoods/seriousjs","bugs":{"url":"https://github.com/wwoods/seriousjs/issues"}}