From fb2bce0cb3f16b44254421e0252f91b1f5190b7c Mon Sep 17 00:00:00 2001 From: Peli de Halleux Date: Mon, 11 May 2015 03:38:32 -0700 Subject: [PATCH] updated docs --- generated/help.cache | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/generated/help.cache b/generated/help.cache index 1f93b97a..e09ea045 100644 --- a/generated/help.cache +++ b/generated/help.cache @@ -2,16 +2,15 @@ "abgjb": "meta version \"v2.2,js,ctx,refs,localcloud,unicodemodel,allasync\";\nmeta name \"widgets\";\nmeta icon \"Callout\";\nmeta color \"#ff9955bb\";\nmeta rootId \"xhf1Sp6J1xBm2sAyHDvS1Bdb\";\nmeta isLibrary \"yes\";\nmeta allowExport \"yes\";\nmeta platform \"current\";\n#main\naction example() {\n // * display a social network message\n code→message(bazaar→current_user, time→now, \"hello!\");\n meta private;\n}\n#message\naction message(user: User, dt: DateTime, text: String) {\n // Displays a message in the current box\n do box {\n box→set_margins(0.2, 0.2, 0.2, 0.5);\n $msg := social→create_message($text);\n $msg→set_from($user→name);\n if $user→has_picture then {\n $msg→set_picture_link(\"https://www.touchdevelop.com/api/\" ∥ web→url_encode($user→id) ∥ \"/picture?which=square\");\n }\n $msg→set_time($dt);\n $msg→post_to_wall;\n }\n meta sync;\n}\n#E1WCAiUZJ9Mv8Ia4upv8cGKG\naction picture(url: String) {\n // Displays a web picture, given a url\n $link := web→link_image($url);\n $link→post_to_wall;\n meta sync;\n}\n", "abtwc": "meta version \"v2.2,js,ctx,refs,localcloud,unicodemodel,allasync\";\nmeta name \"api\";\nmeta rootId \"Pvxrj50J41np0XDuid8EnOb3\";\nmeta hasIds \"yes\";\nmeta platform \"current\";\nmeta parentIds \"\";\n// API reference. #docs #api\n#main\naction main() {\n #xXOjGw5JTxlLDQe2 // {parentTopic:contents}\n #xB2bXN2KGFAR2lm4 // {priority:10}\n #VdNuf8cBJH4XUcbn // **api** stands for **A**plication **P**rogramming **I**nterface [wikipedia](http://en.wikipedia.org/wiki/Application_programming_interface).\n #fHSfp1fQeOWTGr52 // You will find the list of built-in types and actions available in TouchDevelop.\n}\n", "apfwa": "meta version \"v2.2,js,ctx,refs,localcloud,unicodemodel,allasync\";\nmeta name \"blog\";\nmeta rootId \"xWuFaE2vZzUwxkHBZgQ9b4Le\";\nmeta allowExport \"yes\";\nmeta hasIds \"yes\";\nmeta platform \"current\";\nmeta parentIds \"\";\n// All the info about the TouchDevelop blog. #docs\n#mZUeD39600MonBqw\naction main() {\n #YGfAkXjDa3ak2Z7x // {parentTopic:contents}\n #h3xZv3nxc55Ty7qp // The official TouchDevelop community blog is hosted at\n #PJB2w8bkCOOKQPNI // > [](https://www.touchdevelop.com/blog)\n #ewje63A7NtIOj48b // The blog is written by the team members and hopefully soon invited community members. All posts are written in TouchDevelop itself as documentation scripts and pulled by the cloud.\n #xjWg4oNJPpQk7NCe // ### how to write a blog post?\n #o2UVZjWDSQ3hmrpH // All TouchDevelop blog posts are written as TouchDevelop scripts. This allows to create beautiful posts mixing code, images and videos.\n #DDm9sGQNW61IKOsm // * create a new script\n #OAQd72IqjonsmtAk // * add ``#docs #blog`` hashtags to the description.\n #JwnC7pjlA6foqnhv // * add this comment ``{parentTopic:blog}``\n #xXhkz5licxZ0M2TL // * don't forget fill the description: it will be used as a summary on the blog landing page\n #NFZBF4LHpxf21fAg // * don't forget to finish your user profile: set a picture, web site and twitter handle if any.\n #I2L8NHb4FdS9pM6s // When you are ready, publish your script and [send us a message](mailto:touchdevelop@microsoft.com) with your blog post script id. we will review it to see if can be posted on the main TouchDevelop blog.\n #xElV25rsIkDkEftt // ### previous blog\n #NjNG49vP0WyJFucd // When TouchDevelop started, we used Nikolai Tillmann's blog on MSDN. You can find all the previous TouchDevelop entries under\n #xa4VqROkVCZesJsC // > [](http://blogs.msdn.com/b/nikolait/archive/tags/touchdevelop/)\n #vkjQ3q6N7IxIs2MC // * [TouchDevelop: Hour of Code™ 2013 tutorials](http://blogs.msdn.com/b/nikolait/archive/2013/11/26/touchdevelop-hour-of-code-tutorials.aspx)\n #v9K8lBTJClfpcsEx // * [Announcing contest winners + TouchDevelop v3.2: Interactive Tutorials](http://blogs.msdn.com/b/nikolait/archive/2013/11/19/announcing-contest-winners-touchdevelop-v3-2-interactive-tutorials.aspx)\n #x4bDUliWx0MQYocZ // * [cloud data for TouchDevelop released today](http://blogs.msdn.com/b/nikolait/archive/2013/10/28/cloud-data-for-touchdevelop.aspx)\n #R2lmiXq0xPiLx47a // * [Microsoft Touch of Summer 2013 Contest](http://blogs.msdn.com/b/nikolait/archive/2013/10/17/microsoft-touch-of-summer-2013-contest.aspx)\n #XXdtxOaF1NycbeBz // * [Announcing TouchDevelop v3.1: Bluetooth, pin to start, Radio, debugger, profiler, insights, tutorials, videos](http://blogs.msdn.com/b/nikolait/archive/2013/09/19/announcing-touchdevelop-v3-1-bluetooth-debugger-and-more.aspx)\n #PA12Z5Phg6z4jUKf // * [Debugging TouchDevelop scripts](http://blogs.msdn.com/b/nikolait/archive/2013/07/10/debugging-touchdevelop-scripts.aspx)\n #yg656Chmpqbme2nz // * [Announcing TouchDevelop v3.0 for Windows Phone 8: unified experience, new language features, NFC, speech and tile APIs](http://blogs.msdn.com/b/nikolait/archive/2013/06/28/touchdevelop-v3-0-for-windows-phone-8-unified-experience-new-language-features-nfc-speech-tiles.aspx)\n #xaO2uAXiKFGcWLYj // * [TouchDevelop v3.0 beta for Windows Phone 8](http://blogs.msdn.com/b/nikolait/archive/2013/05/14/touchdevelop-v3-0-beta-for-windows-phone-8.aspx)\n #x9F2jBCSAtNXu9Kl // * [expanded device support](http://blogs.msdn.com/b/nikolait/archive/2012/11/27/touchdevelop-create-apps-on-ipad-iphone-android-in-addition-to-pc-mac-windows-phone.aspx)\n #J27g7K92fT9Fe4TF // * [Web App Preview](http://blogs.msdn.com/b/nikolait/archive/2012/10/22/announcing-touchdevelop-web-app-preview.aspx)\n #DZlLfb8eB519gc1x // * [v2.10](http://blogs.msdn.com/b/nikolait/archive/2012/08/28/announcing-touchdevelop-v2-10-tutorial-videos-code-synthesis-trace-replay-and-more.aspx), [v2.8](http://blogs.msdn.com/b/nikolait/archive/2012/05/26/announcing-touchdevelop-v2-8-structured-datatypes-tags-better-pages-buttons-api-search-featured-screenshots.aspx), [v2.6](http://blogs.msdn.com/b/nikolait/archive/2012/02/21/touchdevelop-v2-6-enhanced-user-profiles-libraries-access-devices-in-your-home-network-and-more.aspx), [v2.5](http://blogs.msdn.com/b/nikolait/archive/2011/12/20/touchdevelop-v2-5-new-tutorial-artwork-forum-and-more.aspx), [v2.4](http://blogs.msdn.com/b/nikolait/archive/2011/11/11/touchdevelop-v2-4-push-notifications-updates-discussions.aspx), [v2.3](http://blogs.msdn.com/b/nikolait/archive/2011/10/07/touchdevelop-v2-3-for-mango-pin-to-start-for-scripts.aspx), [v2.2](http://blogs.msdn.com/b/nikolait/archive/2011/09/13/touchdevelop-v2-2-tutorial-mode-improved-code-editor-events.aspx), [v2.1](http://blogs.msdn.com/b/nikolait/archive/2011/08/18/touchdevelop-v2-1-integrated-script-bazaar.aspx), [v2.0](http://blogs.msdn.com/b/nikolait/archive/2011/08/02/announcing-touchdevelop-v2-0-beta-script-sharing-in-the-cloud.aspx), [v1.1](http://blogs.msdn.com/b/nikolait/archive/2011/05/02/touchstudio-update-v1-1-beta.aspx), [v1.0](http://blogs.msdn.com/b/nikolait/archive/2011/04/09/announcing-touchstudio.aspx)\n}\n", -"bhjyb": "meta version \"v2.2,js,ctx,refs,localcloud,unicodemodel,allasync\";\nmeta name \"blank engduino\";\nmeta icon \"CreditCard\";\nmeta color \"#ff00008b\";\nmeta rootId \"SEYbC35yczei4aI3wm7icdMs\";\nmeta iconArtId \"qmjzqlkc\";\nmeta allowExport \"yes\";\nmeta hasIds \"yes\";\nmeta platform \"current\";\nmeta parentIds \"\";\n// A blank Engduino v3 sketch. #arduino #arduinoSketch #Engduink\n#LnSjoBj2DrSx4mcw\naction setup() {\n #mQv6HDl3bdDDAJI0 skip;\n meta private;\n}\n#xq99yDlZpVBNRgrY\naction loop() {\n #xBK6GndqJnRSJkTx @\\u267b→engduino→set_all_LEDs(colors→random);\n #xtbigB2VPSstxCXs @\\u267b→engduino→delay(200);\n #OSTD49T6WAb9oYz6 @\\u267b→engduino→set_all_LEDs(colors→black);\n #jTiWi7fMT5Y0BSEk @\\u267b→engduino→delay(200);\n meta private;\n}\n#xdB9Cm8GWFKxZGcr\naction variables() {\n #khP9iYCJxRB2iUZw skip;\n meta private;\n}\n#Z2bgYR2Rs9Bvcb74\nvar screenshot : Picture {\n is\\_resource = true;\n url = \"https://az31353.vo.msecnd.net/pub/qmjzqlkc\";\n transient = true;\n}\n#XAWEAriEDqFjwWmS meta import engduino {\n pub \"ogmwd\"\n usage {\n\n action `async` set_LED(led_number: Number, color: Color)\n action `async` millis() returns(ms: Number)\n action `async` micros() returns(us: Number)\n action `async` button_pressed() returns(b: Boolean)\n action `async` button_was_pressed() returns(b: Boolean)\n action `async` delay(millis: Number)\n action `async` acceleration() returns(p: Vector3)\n action `async` temperature() returns(p: Number)\n action `async` set_all_LEDs(color: Color)\n }\n #YPEF5gW7PSmp9b4U resolve arduino = ♻ arduino with {\n }\n}\n#uvXS88LcuackBUtZ\naction main() {\n #EuO57UhnSOMDRRlU // This action emulates the code loop in the bug and will not be compiled.\n #Lo714zCo2ze5KJxO code→setup;\n #rTWfhzlllMzajBW8 while true do {\n #xASbcNy6sOwDn24U code→loop;\n }\n}\n#xEqnQPX6C7o8xLVl meta import arduino {\n pub \"cqfda\"\n usage {\n\n action `sync` digital_read(pin: Number) returns(bit: Number)\n action `sync` digital_write(pin: Number, value: Number)\n action `sync` analog_read(pin: Number) returns(bit: Number)\n action `sync` analog_write(pin: Number, value: Number)\n action `async` pin_mode(pin: Number, mode: Number)\n action `sync` HIGH() returns(v: Number)\n action `sync` LOW() returns(v: Number)\n action `sync` OUTPUT() returns(v: Number)\n action `sync` INPUT() returns(v: Number)\n action `async` delay(millis: Number)\n action `sync` sketch(source: String)\n action `sync` static_buffer(bytes: String) returns(buf: Buffer)\n action `sync` INPUT\\_PULLUP() returns(v: Number)\n action `sync` LED\\_BUILTIN() returns(r: Number)\n action `sync` mac(address: String)\n action `sync` analog_reference(type: Number)\n action `sync` DEFAULT() returns(r: Number)\n action `sync` EXTERNAL() returns(r: Number)\n action `sync` tone(pin: Number, frequency: Number, duration: Number)\n action `sync` no_tone(pin: Number)\n action `sync` millis() returns(millis: Number)\n action `sync` micros() returns(micros: Number)\n action `sync` pulse_in(pin: Number, value: Number, timeout: Number) returns(micros: Number)\n action `sync` board(name: String)\n action `sync` print_value(name: String, value: Number)\n action `sync` print(text: String)\n action `sync` println(text: String)\n action `sync` map(value: Number, from_low: Number, from_high: Number, to_low: Number, to_high: Number) returns(r: Number)\n action `sync` constrain(value: Number, a: Number, b: Number) returns(r: Number)\n action `async` delay_microseconds(micros: Number)\n }\n}\n", "ckbk": "meta version \"v2.2,js,ctx,refs,localcloud,unicodemodel,allasync\";\nmeta name \"teach\";\nmeta rootId \"rfFWOBXKYWbKL3882OCwIeVx\";\nmeta hasIds \"yes\";\nmeta platform \"current\";\nmeta parentIds \"\";\n// Teaching with TouchDevelop. #docs #teach #education\n#sJti4PgyaJBMZl5Xa5UMimxW\naction main() {\n #K1y28DAXzlzjVqnx // {parentTopic:contents}\n #sYkQiq3Kz6SzmixV // {priority:100}\n #VE3zvfX2r4Slzd0O // TouchDevelop makes it fun to learn (and teach) programming skills. This section has lots of ideas for using TouchDevelop in the classroom.\n #A6eQBe2sSnp2lUqk // * **Are you a teacher? Join the [TouchDevelop Teachers group](#pub:sxlktprb)!**\n #xQ6nypfXFlgBD7VZ // ### resources for educators\n #iTqjubSk3ck5JnQE // * [Hour Of Code](https://www.touchdevelop.com/hoc) - all the information to run an **Hour Of Code** with TouchDevelop\n #bBTHXKtvHh3YgmNL // * [](/courses) — choose from different curriculum to teach about mobile app and game creation\n #xbbpj2AABJzoZacv // * [](/tutorials) — step by step tutorials to build games and apps\n #Hd33r1xwwgD7qsD7 // * [docs](/contents) — the built-in documentation\n #qQqt5pFCKhlqbNUX // * [](/book) — currently available for free online; systematic introduction to all basic concepts\n #OPjd1hyHfJ39XbW8 // ### environments\n #lLBw4hzsB8IpuVx9 // * The **TouchDevelop Web App** runs in [most modern browsers](https://www.touchdevelop.com/app/current.browsers).\n #Z4En3ihiQz4Dcdfi // * The [TouchDevelop Windows Phone app](http://www.windowsphone.com/s?appId=fe08ccec-a360-e011-81d2-78e7d1fa76f8) gives access to most sensors and data providers available on modern smartphones. [More resources for educators interested in using Windows Phone...](https://www.touchdevelop.com/teachwindowsphone)\n #uc4AzvPR1oVPRmCN // * The [TouchDevelop Android app](https://play.google.com/store/apps/details?id=com.microsoft.touchdevelop) gives access to notifications on Android\n #bAFkE6FP49vQmk4Q // Learn more about [platforms and supported features](https://www.touchdevelop.com/platforms).\n #T4CItQIBnMyWsjzq // ### create your own tutorials and docs\n #RLolkQMEUD0pU4i5 // In addition to creating fun and useful apps, you can use TouchDevelop to create custom interactive tutorials to augment your curriculum. You can also create your own documentation topics adding to the TouchDevelop documentation. This benefits not only your class, but the entire TouchDevelop community!\n #qc2MeCvS62HoY74P // * [creating interactive tutorials](/creatinginteractivetutorials)\n #Esv88v05v32k6UzH // * [add your own docs](/addyourowndocs)\n #cKhwOfsnzrr9c6Ri // ### manage your classroom\n #ZZ80VlTdiwMCWzcy // * You can create [](/groups) and manage your classrooms through them. Groups have a message board and allow to easily collect homework from your students.\n #xo43SANX5LZxfqRT // * Use a [label printer](/labelprinter) to easily get printed labels from student scripts\n #ow6CAnIoZDQOKOLP // ### follow your students\n #t6fGFzG0xF05rZyE // As a teacher, consider [subscribing](/subscriptions) to your students to see what they are publishing and if they are asking questions.\n #ueEDtziGGzDu30Yi // ### experience\n #x2P2jb0Ng0DiKokb // Visit the [TouchDevelop teaching page](http://research.microsoft.com/touchdevelop/teaching.aspx) at Microsoft Research for a list of how TouchDevelop has been used and is being used in classrooms.\n}\n", "cleva": "meta version \"v2.2,js,ctx,refs,localcloud,unicodemodel,allasync,upperplex\";\nmeta name \"blank web api\";\nmeta icon \"Stacks\";\nmeta color \"#ffffffff\";\nmeta rootId \"x4mibwzdISu8zLeLgg7b3IKt\";\nmeta iconArtId \"wyfreugv\";\nmeta isLibrary \"yes\";\nmeta allowExport \"yes\";\nmeta isCloud \"yes\";\nmeta hasIds \"yes\";\nmeta platform \"network,npm,shell\";\nmeta parentIds \"\";\n// An blank web api using Node.JS and Restify. #node #azure #restify\n#czWG9NcXY9uFZHMz\naction \\_init() {\n #rg6M5H46J1bK4x8c data→logger := app→create_logger(\"api\");\n #x2Y2gFv2oHeZKjaB code→init_restify;\n}\n#FrNAgtgAKnFVC43t\naction GET_\\u002fping() returns(#aM0QoLDaWxwAlfSy millis: Number) {\n #xzy3cNZXu2Lbz9f2 // Returns the number of milliseconds since epoch.\n #IYDlx4xcyWX5wD4m $millis := time→now→milliseconds_since_epoch;\n}\n#a4wL0Lb7xeWxhV4L meta import parallel {\n pub \"fncvb\"\n usage {\n type queue\n action `async` @for(count: Number, @action: Number_Action)\n action `async` for_batched(count: Number, batch_count: Number, item_action: Number_Action, batch_action: Action)\n action `sync` schedule(q: ♻ parallel → queue, task: Action)\n action `sync` create_queue(max_running: Number) returns(queue: ♻ parallel → queue)\n action `async` wait_for_empty(q: ♻ parallel → queue)\n action `async` for_json(js: Json_Object, @action: Json_Action)\n }\n}\n#CW3Wao3uu3Z2Fhe6\nvar logger : App_Logger {\n transient = true;\n}\n#rmfzWWMIFG8Ule9I\naction init_restify() {\n #GL26xBm2sW9gi51S $server := @\\u267b→restify→server;\n #eq0FvCwwbob1i3UD $server→use(@\\u267b→restify→authorization_parser);\n #Ee6qD4jb4Xr4TCYg $server→pre(@\\u267b→restify→sanitize_path);\n #xiHn2sJ7jyfBOFLf $throttle := @\\u267b→restify→throttle;\n #ZU1qf4WMSwf2ZZs8 where rate := 40;\n #S04R2349FF42Rb2O where burst := 100;\n #qa878gtstkVP7tTO where ip := true;\n #kld3kZpnFcZ4TVhB $server→use($throttle);\n #sptEZCs70xCB68CA $server→use(@\\u267b→restify→CORS);\n #mFFPDO74C64OWH8s $server→use(@\\u267b→restify→body_parser);\n #xSqpOmBEP6L2VCFi $server→use(@\\u267b→restify→gzip_response);\n #xR4QGtRsV3hGoSJQ $server→use(@\\u267b→restify→query_parser);\n #x9bNZzJ9tZk0l1Z4 $server→use(@\\u267b→restify→conditional_request);\n #buXcIfKig0apgL4x @\\u267b→restify_touchdevelop→autobind($server);\n #kj30VDMt3gkmKiZM code→init_routes();\n #UAx1DGb27XEqkYO5 $server→use(@\\u267b→restify_touchdevelop→errors_to_log(data→logger));\n meta private;\n}\n#Png4V3OlrtBkrIAa meta import restify {\n pub \"egzra\"\n usage {\n action `async` `type` Request_Handler(req: ♻ restify → Request, res: ♻ restify → Response)\n #xLPhdjOebDT8w77X\n table Throttle_Options {\n type = \"Object\";\n exported = true;\n persistent = false;\n fields {\n #xo6LfV0hyAQtz675 rate : Number\n #yZ2QZAfeW3W74JA1 burst : Number\n #JUlNvDq7Hm9cTUAG ip : Boolean\n #w2h4dcf4I5K5h7kn xff : Boolean\n #RO3Sx6iTt4WsVBm6 username : Boolean\n #VbsYnDvr3t4Xr4VA maxKeys : Number\n #w25h9R5LKJnWiBNu tokensTable : ♻ restify → Tokens_Table\n }\n }\n #xdeuBx505IsZ6eEI\n table Serve_Static_Options {\n type = \"Object\";\n exported = true;\n persistent = false;\n fields {\n #NfWLVJBBbHvtMqkl default : String\n #KvIMj1sEoAwQCf22 maxAge : Number\n }\n }\n #mqEMUbizkEp6naSD\n table CORS_Options {\n type = \"Object\";\n exported = true;\n persistent = false;\n fields {\n #xMYYV6C3eS7PWsfQ origins : String\n #z5HdpFdSi792e1OX credentials : Boolean\n #Fw1D0A9ZfeMCf5c3 headers : String\n }\n }\n #w2zTzWkfMf01yOko\n table Body_Parser_Options {\n type = \"Object\";\n exported = true;\n persistent = false;\n fields {\n #mhaHCLobgUgMrv72 maxBodySize : Number\n #xr4fKleNd4wHHP1l mapParams : Boolean\n #st0ir2vLTxbLTQWB mapFiles : Boolean\n #z5ah2mZWb8c5FmTM overrideParams : Boolean\n }\n }\n #xv4yZciZi2wFoqpM\n table Send_Options {\n type = \"Object\";\n exported = true;\n persistent = false;\n fields {\n #svWYln7UIackFIpB status : Number\n }\n }\n type Request\n type Response\n type Tokens_Table\n type Server\n type Middleware\n type Error\n action `sync` use(server: ♻ restify → Server, mid: ♻ restify → Middleware)\n action `sync` get(server: ♻ restify → Server, path: String, @then: ♻ restify → Request_Handler)\n action `sync` post(server: ♻ restify → Server, path: String, @then: ♻ restify → Request_Handler)\n action `sync` server() returns(server: ♻ restify → Server)\n action `sync` send(res: ♻ restify → Response, content: String, options\\u003f: ♻ restify → Send_Options)\n action `sync` status(res: ♻ restify → Response, status: Number)\n action `sync` is(req: ♻ restify → Request, type: String) returns(r: Boolean)\n action `sync` accepts(req: ♻ restify → Request, types: String) returns(type: String)\n action `sync` put(server: ♻ restify → Server, path: String, @then: ♻ restify → Request_Handler)\n action `sync` del(server: ♻ restify → Server, path: String, @then: ♻ restify → Request_Handler)\n action `sync` head(server: ♻ restify → Server, path: String, @then: ♻ restify → Request_Handler)\n action `sync` pre(server: ♻ restify → Server, mid: ♻ restify → Middleware)\n action `sync` CORS(options\\u003f: ♻ restify → CORS_Options) returns(mid: ♻ restify → Middleware)\n action `sync` conditional_request() returns(mid: ♻ restify → Middleware)\n action `sync` route(server: ♻ restify → Server, method: String, path: String, @then: ♻ restify → Request_Handler)\n action `sync` json(res: ♻ restify → Response, content: Json_Object, options\\u003f: ♻ restify → Send_Options)\n action `sync` next(res: ♻ restify → Response)\n action `sync` next_error(res: ♻ restify → Response, error: ♻ restify → Error)\n action `sync` address(server: ♻ restify → Server) returns(address: String)\n action `sync` gzip_response() returns(mid: ♻ restify → Middleware)\n action `sync` header(req: ♻ restify → Request, name: String) returns(value: String)\n action `sync` is_secure(req: ♻ restify → Request) returns(r: Boolean)\n action `sync` is_chunked(req: ♻ restify → Request) returns(r: Boolean)\n action `sync` is_keep_alive(req: ♻ restify → Request) returns(r: Boolean)\n action `sync` set_header(res: ♻ restify → Response, name: String, value: String)\n action `sync` body_parser(options\\u003f: ♻ restify → Body_Parser_Options) returns(mid: ♻ restify → Middleware)\n action `sync` throttle(options\\u003f: ♻ restify → Throttle_Options) returns(middleware: ♻ restify → Middleware)\n action `sync` date_parser(clock_skew: Number) returns(middleware: ♻ restify → Middleware)\n action `sync` serve_static(directory: String, options\\u003f: ♻ restify → Serve_Static_Options) returns(middleware: ♻ restify → Middleware)\n action `sync` query_parser() returns(middleware: ♻ restify → Middleware)\n action `sync` authorization_parser() returns(middleware: ♻ restify → Middleware)\n action `sync` jsonp() returns(middleware: ♻ restify → Middleware)\n action `sync` body_as_json(req: ♻ restify → Request) returns(body: Json_Object)\n action `sync` id(req: ♻ restify → Request) returns(id: String)\n action `sync` param(req: ♻ restify → Request, name: String) returns(value: String)\n action `sync` opts(server: ♻ restify → Server, path: String, @then: ♻ restify → Request_Handler)\n action `sync` patch(server: ♻ restify → Server, path: String, @then: ♻ restify → Request_Handler)\n action `sync` to_string(ser: ♻ restify → Server) returns(s: String)\n action `sync` sanitize_path() returns(middleware: ♻ restify → Middleware)\n action `sync` body(req: ♻ restify → Request) returns(body: String)\n action `sync` send_error(res: ♻ restify → Response, status: Number, message: String)\n action `sync` all(server: ♻ restify → Server, @then: ♻ restify → Request_Handler)\n action `sync` method(req: ♻ restify → Request) returns(method: String)\n action `sync` url(req: ♻ restify → Request) returns(url: String)\n action `sync` query(req: ♻ restify → Request) returns(query: Json_Object)\n action `sync` redirect(res: ♻ restify → Response, status_code: Number, url: String)\n action `sync` send_status(res: ♻ restify → Response, status_code: Number)\n action `sync` charset(res: ♻ restify → Response, encoding: String)\n action `sync` route_regex(server: ♻ restify → Server, method: String, path_regex: String, @then: ♻ restify → Request_Handler)\n action `async` read_body_as_buffer(req: ♻ restify → Request) returns(body: Buffer)\n action `sync` headers(req: ♻ restify → Request) returns(headers: Json_Object)\n action `sync` server_url(req: ♻ restify → Request) returns(url: String)\n action `sync` html(res: ♻ restify → Response, content: String, options\\u003f: ♻ restify → Send_Options)\n }\n}\n#MLbRHC7j0u4Bo4GQ meta import restify_touchdevelop {\n pub \"dvuhb\"\n usage {\n action `sync` autobind(server: ♻ restify → Server)\n action `sync` errors_to_log(logger: App_Logger) returns(middleware: ♻ restify → Middleware)\n }\n #OzaDw2jYXC1r4oMK resolve restify = ♻ restify with {\n }\n}\n#xcZnKOBpfz0lu8jD\naction init_routes() {\n #MxIs21VA5KpTC0F8 $server := @\\u267b→restify→server;\n #B2Ui2S2BrMhefyH4 $server→get(\"/echo\", $@then);\n #c58sWTLqXwkWaboA where @then(req: ♻ restify → Request, res: ♻ restify → Response) {\n #yXsNFxumA3UsfrbL $res→send($req→body);\n }\n meta private;\n}\n#XtmWYupkIPBJS394 meta import node_hash {\n pub \"ezbka\"\n usage {\n action `sync` sha256(value: String) returns(digest: String)\n action `sync` sha1(value: String) returns(digest: String)\n }\n #GWvhSP7JyKU8z6PI resolve node_crypto = ♻ node_crypto with {\n }\n}\n#el5rlGit0kOOkLrC meta import node_crypto {\n pub \"ujtrc\"\n usage {\n type credentials\n type hash\n type hmac\n type cipher\n type decipher\n type sign\n type verify\n type DiffieHellman\n action `sync` get_ciphers() returns(ciphers: Collection[String])\n action `sync` get_hashes() returns(hashes: Collection[String])\n action `sync` create_credentials(details: Json_Object) returns(credentials: ♻ node_crypto → credentials)\n action `sync` create_hash(algorithm: String) returns(hash: ♻ node_crypto → hash)\n action `sync` update_hash(hash: ♻ node_crypto → hash, hash_data: Buffer)\n action `sync` digest_hash(hash: ♻ node_crypto → hash) returns(digest: Buffer)\n action `sync` update_hmac(hmac: ♻ node_crypto → hmac, hmac_data: Buffer)\n action `sync` digest_hmac(hmac: ♻ node_crypto → hmac) returns(digest: Buffer)\n action `sync` create_cipher(algorithm: String, password: Buffer) returns(cipher: ♻ node_crypto → cipher)\n action `sync` create_cipher_iv(algorithm: String, key: Buffer, iv: Buffer) returns(iv_cipher: ♻ node_crypto → cipher)\n action `sync` update_cipher(cipher: ♻ node_crypto → cipher, _data: Buffer) returns(enciphered: Buffer)\n action `sync` final(cipher: ♻ node_crypto → cipher) returns(cipher_final: Buffer)\n action `sync` set_auto_padding(cipher: ♻ node_crypto → cipher)\n action `sync` create_decipher(algorithm: String, password: Buffer) returns(decipher: ♻ node_crypto → decipher)\n action `sync` create_decipher_iv(algorithm: String, key: Buffer, iv: Buffer) returns(iv_decipher: ♻ node_crypto → decipher)\n action `sync` update_decipher(decipher: ♻ node_crypto → decipher, _data: Buffer) returns(deciphered: Buffer)\n action `sync` final_(decipher: ♻ node_crypto → decipher) returns(decipher_final: Buffer)\n action `sync` set_auto_padding_(decipher: ♻ node_crypto → decipher)\n action `sync` create_sign(algorithm: String) returns(sign: ♻ node_crypto → sign)\n action `sync` update_sign(sign: ♻ node_crypto → sign, sign\\_data: Buffer)\n action `sync` sign_(sign: ♻ node_crypto → sign, private_key: String) returns(signature: Buffer)\n action `sync` create_verify(algorithm: String) returns(verify: ♻ node_crypto → verify)\n action `sync` update_verify(verify: ♻ node_crypto → verify, verify_data: Buffer)\n action `sync` verify_(verify: ♻ node_crypto → verify, object: String, signature: Buffer) returns(valid: Boolean)\n action `sync` create_DiffieHellman(prime_length: Number) returns(DiffieHellman: ♻ node_crypto → DiffieHellman)\n action `sync` generate_keys(DiffieHellman: ♻ node_crypto → DiffieHellman) returns(public_key: Buffer)\n action `sync` compute_secret(DiffieHellman: ♻ node_crypto → DiffieHellman, other_public_key: Buffer) returns(shared_secret: Buffer)\n action `sync` get_prime(DiffieHellman: ♻ node_crypto → DiffieHellman) returns(DH_prime: Buffer)\n action `sync` get_generator(DiffieHellman: ♻ node_crypto → DiffieHellman) returns(generator: Buffer)\n action `sync` get_public_key(DiffieHellman: ♻ node_crypto → DiffieHellman) returns(public_key: Buffer)\n action `sync` get_private_key(DiffieHellman: ♻ node_crypto → DiffieHellman) returns(private_key: Buffer)\n action `sync` set_public_key(DiffieHellman: ♻ node_crypto → DiffieHellman, public_key: Buffer)\n action `sync` set_private_key(DiffieHellman: ♻ node_crypto → DiffieHellman, private_key: Buffer)\n action `sync` get_DiffieHellman(group_name: String) returns(DiffieHellman: ♻ node_crypto → DiffieHellman)\n action `async` pbkdf2(password: String, salt: String, iterations: Number, keylen: Number) returns(derived_key: String)\n action `async` random_bytes(size: Number) returns(strong_data: Buffer)\n action `sync` DEFAULT\\_ENCODING() returns(default_encoding: String)\n action `sync` create_hmac(algorithm: String, key: String) returns(hmac: ♻ node_crypto → hmac)\n action `sync` create_DiffieHellmanWithPrime(prime: Buffer) returns(DiffieHellman: ♻ node_crypto → DiffieHellman)\n action `async` pseudo_random_bytes(size: Number) returns(non\\u002dstrong_data: Buffer)\n action `sync` update_hash_string(hash: ♻ node_crypto → hash, hash_data: String)\n }\n}\n", -"cljk": "meta version \"v2.2,js,ctx,refs,localcloud,unicodemodel,allasync\";\nmeta name \"getting started\";\nmeta icon \"CoffeeCup\";\nmeta color \"#ff007fff\";\nmeta rootId \"jgxw4hrQ2FJpvMX5ioKe2B98\";\nmeta hasIds \"yes\";\nmeta platform \"current\";\nmeta parentIds \"\";\n// A few tips on getting started with TouchDevelop. #docs #gettingStarted\n#xIo02XpbLanjKZPs4Os6Y4LA\naction main() {\n #Oqq61gE3scTEvYZY // {parentTopic:contents}\n #zLfUy9LLj4LtaQx1 // {priority:15}\n #BtM6DR2J5yHB6sPI // TouchDevelop lets you **create apps** on all your devices. Let's get started!\n #xTc92pAlcVjk7NIM // ## interactive tutorials\n #UR4kehofIixy8ZqD // Interactive tutorials let you learn at your own pace. We recommend starting out with one or more of these:\n #BMpEHAl89GLjB6Tj // * {follow:first steps with turtle}\n #RyRvlr3i8Xt2QwpU // * {follow:jumping bird tutorial}\n #ZQgFR1AVUm6THyGs // * {follow:coding jetpack jumper}\n #zObCeEa9dPLp8ooa // * {follow:pixel art tutorial}\n #zxrf3iOVA2LWSucN // Try also\n #q9JFJmh12AXcgatn // * [build your first app](http://aka.ms/buildyourfirstapp)\n #Fi2zIopLiFb4rNH4 // * Run an [Hour Of Code](https://www.touchdevelop.com/hoc) with TouchDevelop!\n #yx3F7H4uaTmcHwkO // Browse many other [interactive tutorials](/tutorials) and [courses](/courses). Learn how to build your own games, social apps, and more! Also, check out the book [TouchDevelop - Programming on the Go](/book). It's available as a free download!\n #xJmv15REfU94PGim // ## if you have programming experience...\n #fl1IdthF70YHQxDf // ### Traditional Languages\n #ss44jvTWrjOMlUod // {pic:eclipse:12x5}\n #h4UEzbiXxngho4qF // If you have experience with a traditional programming language such as Java, JavaScript, Python, C#, or C++:\n #P2cb12dV12LdnGN4 // * Start with [hello world](/helloworld) and create a TouchDevelop version of the classic 'hello world' app.\n #Tk1HQSMDs4fk4SuF // * Go to the [dev boot camp](/devbootcamp) and get a quick overview of the TouchDevelop language and environment.\n #xqE7TP69LpivSkjp // * Try a [social app tutorial](/socialapptutorials).\n #xM8eoCxsFuNcZ6Lc // ### Block Programming Environments\n #A6h4niF5i1xLuOXm // {pic:scratch:11x4}\n #k1oezDF4jvXHgk3V // If you have experience with block programming environments such as **Scratch**, **AppInventor**, **Snap!** (BYOB), **code.org**, **Blockly**, or other tools, let us show you how to [transition from blocks to text](/fromblockstotext).\n #KY8dTaEdqs4sjpRG // ## inform and instruct\n #Retn7qEvVW1pvEQZ // In addition to creating fun and useful apps, you can use TouchDevelop to create custom interactive tutorials to show users how to perform specific tasks. You can also create your own documentation topics to expand the TouchDevelop documentation!\n #xCY1IPuWs8bC15Fj // * [creating interactive tutorials](/creatinginteractivetutorials)\n #HIy9PSdtPgJXRY8Z // * [add your own docs](/addyourowndocs)\n}\n#kZWqFwNpvbKrHfETZ2TSQKCA\nvar scratch : Picture {\n is\\_resource = true;\n url = \"https://az31353.vo.msecnd.net/pub/fpxfkwlk\";\n transient = true;\n}\n#b97YU9g2RQFdWzG22RPqgK2Y\nvar eclipse : Picture {\n is\\_resource = true;\n url = \"https://az31353.vo.msecnd.net/pub/srtrixfh\";\n transient = true;\n}\n#SxNnQzF2puTSD7MMUORJP2UN\nvar turtle : Picture {\n is\\_resource = true;\n url = \"https://az31353.vo.msecnd.net/pub/pskgnelo\";\n transient = true;\n}\n", "cwgn": "meta version \"v2.2,js,ctx,refs,localcloud,unicodemodel,allasync\";\nmeta name \"layout\";\nmeta icon \"NineColumn\";\nmeta color \"#ff9955bb\";\nmeta rootId \"J2g52kon8pb1Qs9cRhmPGKZu\";\nmeta isLibrary \"yes\";\nmeta allowExport \"yes\";\nmeta platform \"current\";\n// A library to help with laying out boxes.\n#main\naction example() {\n // This library provides various helpers to simplify the layout of boxes.\n // * layout vertically or horizontally based on the page orientation\n do box {\n code→use_flexible_layout;\n // ...\n }\n // * stretch and center a box\n do box {\n code→stretch_and_center;\n // ...\n }\n meta private;\n meta test;\n}\n#fADj2RlGhi2LmT1rCUpyRpxM\naction stretch_and_center() {\n // Stretches horizontally and vertically the current box and aligns the content with the center.\n box→set_horizontal_stretch(1);\n box→set_horizontal_align(\"center\");\n box→set_vertical_stretch(1);\n box→set_vertical_align(\"center\");\n meta sync;\n}\n#QpiD4W44RMmIzOZmyI6706Ps\naction use_flexible_layout() {\n // Uses **horizontal layout** if the page is landscape; **vertical layout** if the page is portrait.\n if box→page_width > box→page_height then {\n box→use_horizontal_layout;\n }\n else {\n box→use_vertical_layout;\n }\n meta private;\n meta sync;\n}\n#gridofsquares\naction grid_of_squares(cell_content: Number_Action, count: Number, grid_width: Number, grid_height: Number) {\n // Draw a grid of at least (count) squares, of the specified total width and height.\n $numboxes := $count;\n $Area := $grid_width * $grid_height;\n $bsize := math→sqrt($Area / $numboxes);\n $cols := math→floor($grid_width / $bsize);\n $rows := math→ceiling($numboxes / $cols);\n while $rows * $bsize > $grid_height do {\n $alt1 := $grid_width / ($cols + 1) - .001;\n $alt2 := $grid_height / $rows - 0.001;\n $bsize := math→max($alt1, $alt2);\n $cols := math→floor($grid_width / $bsize);\n $rows := math→ceiling($numboxes / $cols);\n }\n $mgn := .03 * $bsize;\n if $mgn * box→pixels_per_em < 2 then {\n $mgn := 2 / box→pixels_per_em;\n }\n $bsize := $bsize - $mgn;\n do box {\n code→draw_grid($rows, $cols, $mgn, $bsize, $cell_content, 0);\n }\n}\n#drawgrid\naction draw_grid(rows: Number, cols: Number, margin: Number, bsize: Number, cell_content: Number_Action, offset: Number) {\n box→set_height($rows * $bsize + ($rows - 1) * $margin);\n box→use_vertical_layout;\n box→set_vertical_align(\"justify\");\n for 0 ≤ i < $rows do {\n do box {\n box→set_width($cols * $bsize + ($cols - 1) * $margin);\n box→use_horizontal_layout;\n box→set_horizontal_align(\"justify\");\n for 0 ≤ j < $cols do {\n do box {\n do box {\n box→set_width($bsize);\n box→set_height($bsize);\n $cell_content→run($offset + $i * $cols + $j);\n }\n }\n }\n }\n }\n meta private;\n}\n#horizontallyscrollin\naction horizontal_hub_of_squares(cell_content: Number_Action, count: Number, cell_size: Number, group_width: Number, total_height: Number) {\n // Draw a horizontally scrolling grid of at least (count) squares of the specified size, with the specified total height.\n $numboxes := $count;\n $mgn := .03 * $cell_size;\n if $mgn * box→pixels_per_em < 2 then {\n $mgn := 2 / box→pixels_per_em;\n }\n $bsize := $cell_size + $mgn;\n $cols := math→floor($group_width / $bsize);\n $rows := math→floor($total_height / $bsize);\n if $cols ≤ 0 then {\n $cols := $rows;\n }\n $groups := math→ceiling($numboxes / ($rows * $cols));\n box→use_horizontal_layout;\n for 0 ≤ i < $groups do {\n do box {\n if $i ≠ 0 then {\n box→set_margins(0, 0, 0, .2 * $bsize);\n }\n code→draw_grid($rows, $cols, $mgn, $cell_size, $cell_content, $i * ($rows * $cols));\n }\n }\n box→set_scrolling(true, false);\n}\n#verticallyscrollings\naction vertical_hub_of_squares(cell_content: Number_Action, count: Number, cell_size: Number, total_width: Number, group_height: Number) {\n // Draw a vertically scrolling grid of at least (count) squares of the specified size, with the specified total width.\n $numboxes := $count;\n $mgn := .03 * $cell_size;\n if $mgn * box→pixels_per_em < 2 then {\n $mgn := 2 / box→pixels_per_em;\n }\n $bsize := $cell_size + $mgn;\n $cols := math→floor($total_width / $bsize);\n $rows := math→floor($group_height / $bsize);\n if $rows ≤ 0 then {\n $rows := $cols;\n }\n $groups := math→ceiling($numboxes / ($rows * $cols));\n box→use_vertical_layout;\n for 0 ≤ i < $groups do {\n do box {\n if $i ≠ 0 then {\n box→set_margins(.2 * $bsize, 0, 0, 0);\n }\n code→draw_grid($rows, $cols, $mgn, $cell_size, $cell_content, $i * ($rows * $cols));\n }\n }\n box→set_scrolling(false, true);\n}\n", "enyra": "meta version \"v2.2,js,ctx,refs,localcloud,unicodemodel,allasync\";\nmeta name \"blank scratch\";\nmeta icon \"Flag\";\nmeta color \"#ffffa500\";\nmeta rootId \"DW2rPXfOGG0eQFu92NcRb5TE\";\nmeta platform \"current\";\n// #scratch\n#mNUzNyy2wxUPIVGaxSd7qyIc\naction main() {\n skip;\n}\n#scratch meta import scratch {\n pub \"cagwa\"\n usage {\n type scratch_sprite\n action `sync` new_sprite(pic: Picture) returns(sprite: ♻ scratch → scratch_sprite)\n action `async` move(sprite: ♻ scratch → scratch_sprite, steps: Number)\n action `async` say_for(sprite: ♻ scratch → scratch_sprite, text: String, seconds: Number)\n action `sync` play_sound(sound: Sound)\n action `async` play_sound_until_done(sound: Sound)\n action `async` turn_left(sprite: ♻ scratch → scratch_sprite, degrees: Number)\n action `async` turn_right(sprite: ♻ scratch → scratch_sprite, degrees: Number)\n action `sync` x_position(sprite: ♻ scratch → scratch_sprite) returns(x: Number)\n action `sync` y_position(sprite: ♻ scratch → scratch_sprite) returns(y: Number)\n action `sync` grid()\n action `async` change_x_by(sprite: ♻ scratch → scratch_sprite, amount: Number)\n action `async` change_y_by(sprite: ♻ scratch → scratch_sprite, amount: Number)\n action `sync` set_y_to(sprite: ♻ scratch → scratch_sprite, y: Number)\n action `sync` set_x_to(sprite: ♻ scratch → scratch_sprite, x: Number)\n action `sync` direction(sprite: ♻ scratch → scratch_sprite) returns(d: Number)\n action `async` point_in_direction(sprite: ♻ scratch → scratch_sprite, degrees: Number)\n action `async` glide_to(sprite: ♻ scratch → scratch_sprite, duration: Number, x: Number, y: Number)\n action `async` go_to_x_y(sprite: ♻ scratch → scratch_sprite, x: Number, y: Number)\n action `async` show(sprite: ♻ scratch → scratch_sprite)\n action `async` hide(sprite: ♻ scratch → scratch_sprite)\n action `async` change_size_by(sprite: ♻ scratch → scratch_sprite, amount: Number)\n action `sync` size(sprite: ♻ scratch → scratch_sprite) returns(size: Number)\n action `async` wait(seconds: Number)\n action `sync` mouse_down\\u003f() returns(b: Boolean)\n action `sync` mouse_y() returns(x: Number)\n action `sync` mouse_x() returns(x: Number)\n action `sync` pick_random(start: Number, end: Number) returns(r: Number)\n action `sync` user_name() returns(name: String)\n action `sync` user_picture() returns(pic: Picture)\n action `sync` ask_and_wait(text: String) returns(answer: String)\n action `sync` go_to_front(sprite: ♻ scratch → scratch_sprite)\n action `sync` go_back(sprite: ♻ scratch → scratch_sprite, layers: Number)\n action `sync` if_on_edge\\u002c_bounce(sprite: ♻ scratch → scratch_sprite)\n action `sync` switch_backdrop_to(backdrop: Picture)\n action `sync` current_time() returns(now: DateTime)\n action `sync` when_clicked(sprite: ♻ scratch → scratch_sprite, clicked: Action)\n action `sync` distance_to(sprite: ♻ scratch → scratch_sprite, other: ♻ scratch → scratch_sprite) returns(d: Number)\n action `sync` point_towards(sprite: ♻ scratch → scratch_sprite, other: ♻ scratch → scratch_sprite)\n action `sync` mouse\\u002dpointer() returns(m: ♻ scratch → scratch_sprite)\n action `sync` timer() returns(t: Number)\n action `sync` reset_timer()\n action `sync` when_backdrop_clicked(clicked: Position_Action)\n action `async` go_to(sprite: ♻ scratch → scratch_sprite, other: ♻ scratch → scratch_sprite)\n action `async` next_costume(sprite: ♻ scratch → scratch_sprite)\n action `async` add_costume(sprite: ♻ scratch → scratch_sprite, pic: Picture)\n action `async` say(sprite: ♻ scratch → scratch_sprite, text: String)\n action `sync` when_flag_clicked(clicked: Action)\n action `sync` create_clone(sprite: ♻ scratch → scratch_sprite) returns(clone: ♻ scratch → scratch_sprite)\n action `sync` touching(sprite: ♻ scratch → scratch_sprite, other: ♻ scratch → scratch_sprite) returns(b: Boolean)\n action `sync` x_speed(sprite: ♻ scratch → scratch_sprite) returns(vx: Number)\n action `sync` y_speed(sprite: ♻ scratch → scratch_sprite) returns(y: Number)\n action `sync` change_speed_x_by(sprite: ♻ scratch → scratch_sprite, amount: Number)\n action `sync` change_speed_y_by(sprite: ♻ scratch → scratch_sprite, amount: Number)\n action `sync` x_acceleration(sprite: ♻ scratch → scratch_sprite) returns(ax: Number)\n action `sync` y_acceleration(sprite: ♻ scratch → scratch_sprite) returns(ay: Number)\n action `sync` change_x_acceleration_by(sprite: ♻ scratch → scratch_sprite, amount: Number)\n action `sync` change_y_acceleration_by(sprite: ♻ scratch → scratch_sprite, amount: Number)\n action `sync` set_x_speed_to(sprite: ♻ scratch → scratch_sprite, speed: Number)\n action `sync` set_y_speed_to(sprite: ♻ scratch → scratch_sprite, speed: Number)\n action `sync` set_x_acceleration_to(sprite: ♻ scratch → scratch_sprite, acceleration: Number)\n action `sync` set_y_acceleration_to(sprite: ♻ scratch → scratch_sprite, acceleration: Number)\n action `sync` forever(@action: Action)\n action `sync` friction(sprite: ♻ scratch → scratch_sprite) returns(f: Number)\n action `sync` set_friction_to(sprite: ♻ scratch → scratch_sprite, friction: Number)\n action `sync` when_swipped(sprite: ♻ scratch → scratch_sprite, swiped: Vector_Action)\n action `sync` when_backdrop_swiped(swiped: Vector_Action)\n action `sync` device_x_acceleration() returns(dev_ax: Number)\n action `sync` device_y_acceleration() returns(dev_ay: Number)\n action `sync` bounce_on_edges()\n action `async` set_size_to(sprite: ♻ scratch → scratch_sprite, percent: Number)\n action `async` clear()\n action `sync` pen_down(sprite: ♻ scratch → scratch_sprite)\n action `sync` pen_up(sprite: ♻ scratch → scratch_sprite)\n action `sync` set_pen_color_to(sprite: ♻ scratch → scratch_sprite, c: Color)\n action `sync` set_pen_color_to_wheel(sprite: ♻ scratch → scratch_sprite, c: Number)\n action `sync` change_pen_color_by(sprite: ♻ scratch → scratch_sprite, amount: Number)\n action `sync` set_pen_size_to(sprite: ♻ scratch → scratch_sprite, size: Number)\n action `sync` change_pen_size_by(sprite: ♻ scratch → scratch_sprite, amount: Number)\n action `sync` stamp(sprite: ♻ scratch → scratch_sprite)\n action `sync` join(left: String, right: String) returns(s: String)\n action `sync` letter_of(index: Number, s: String) returns(c: String)\n action `sync` length(s: String) returns(r: Number)\n action `sync` stop_all()\n action `async` new_rectangle_sprite(color: Color, width: Number, height: Number) returns(sprite: ♻ scratch → scratch_sprite)\n action `sync` key_pressed\\u003f(key: String) returns(b: Boolean)\n action `sync` when_key_pressed(key: String, @action: Action)\n }\n}\n", "exvp": "meta version \"v2.2,js,ctx,refs,localcloud,unicodemodel,allasync\";\nmeta name \"blank office mix\";\nmeta icon \"AddressBook\";\nmeta rootId \"w0BIoDnMjckDm4IxHPWUL5LO\";\nmeta allowExport \"yes\";\nmeta platform \"current\";\n#theme meta import theme {\n pub \"gnvi\"\n usage {\n action `async` title_1()\n action `async` title_2()\n action `async` title_3()\n action `async` subtle()\n action `async` normal()\n action `sync` example()\n action `async` accent()\n action `async` set_right_aligned(value: Boolean)\n action `async` huge()\n }\n}\n#main\naction slideshow_view(\\u2756: * slideshow_view_page_data) {\n if box→is_init then {\n code→load_settings;\n }\n if true then {\n // We show the question taken as input in the Edit Mode. The answer is passed to the Input Activity created in Edit Mode (and referred by index `0`).\n do box {\n data→settings→question→post_to_wall;\n }\n @\\u267b→forms→input_text_area(\"\", $\\u2756→text→\\u25c8ref);\n @\\u267b→forms→button(\"submit\", $on_tapped);\n where on_tapped() {\n $slideshow := @\\u267b→office_mix→current_viewer;\n $slideshow→complete_input_activity(0, $\\u2756→text, 1, true);\n $slideshow→next_slide;\n }\n }\n meta private;\n meta page;\n meta sync;\n}\n#BbWFpbiBwYWdlIGRhdGEa\ntable slideshow_view_page_data {\n type = \"Object\";\n persistent = false;\n fields {\n #mxIky6R9ZTE4uS48eYA6Q8jB text : String\n }\n}\n#YZGaVg1jhqq9sfncCGsIoHbh meta import forms {\n pub \"rwffb\"\n usage {\n action `sync` `type` display_code()\n action `sync` `type` validator(s: String) returns(error: String)\n action `sync` button(text: String, on_tapped: Action)\n action `sync` checkbox(text: String, checked: Ref[Boolean])\n action `sync` show_example()\n action `sync` input_string_collection(label: String, strings: String_Collection)\n action `sync` input_text_line(label: String, text: Ref[String])\n action `sync` input_text_area(label: String, text: Ref[String])\n action `sync` input_password(label: String, password: Ref[String])\n action `sync` input_number(label: String, text: Ref[String], changehandler: Number_Action)\n action `sync` labeled_content(label: String, content: display_code)\n action `sync` indented_content(content: display_code)\n action `sync` input_choice(label: String, choices: String_Collection, index: Ref[Number])\n action `sync` input_text_line_w\\u002f_validator(label: String, text: Ref[String], errorcheck: validator, changehandler: Text_Action)\n }\n}\n#LHF2iIBnkOQcwhcoQKFiR4A2 meta import widgets {\n pub \"abgjb\"\n usage {\n action `sync` message(user: User, dt: DateTime, text: String)\n action `sync` picture(url: String)\n }\n}\n#iDxzKDq4042OKy7IX4V4D91F meta import layout {\n pub \"cwgn\"\n usage {\n action `sync` stretch_and_center()\n action `async` grid_of_squares(cell_content: Number_Action, count: Number, grid_width: Number, grid_height: Number)\n action `async` horizontal_hub_of_squares(cell_content: Number_Action, count: Number, cell_size: Number, group_width: Number, total_height: Number)\n action `async` vertical_hub_of_squares(cell_content: Number_Action, count: Number, cell_size: Number, total_width: Number, group_height: Number)\n }\n}\n#BdGhpbmca\ntable Settings {\n type = \"Object\";\n persistent = false;\n fields {\n #qkFSUVeLWy15xGwkOSkxcgi8 question : String\n }\n}\n#xlTdxT5HNK4dNq8WHyG47gDw\naction main() {\n // See `Office Mix` library for more documentation.\n @\\u267b→office_mix→connect;\n if @\\u267b→office_mix→is_edit_mode then {\n // `Edit Mode` is activated when the user opens your app while making the slides.\n code→settings_view;\n }\n else { if @\\u267b→office_mix→is_view_mode then {\n // `View Mode` is fired when the slide containing your app is activated on a slideshow or in Mix lesson player.\n code→slideshow_view;\n }\n else { } } \n}\n#megDAnWFZthpuq80jwFuWisO\nvar settings : * Settings {\n // Add fields that need to be stored for the configuration of the app.\n transient = true;\n}\n#UW3iOsSblj12g3meTHz4P9yV\naction settings_view(\\u2756: * settings_view_page_data) {\n if box→is_init then {\n code→load_settings;\n wall→set_subtitle(\"settings\");\n }\n if true then {\n // This app stores a question from the user.\n @\\u267b→forms→input_text_area(\"Question\", data→settings→question→\\u25c8ref);\n @\\u267b→forms→button(\"save\", $on_tapped);\n where on_tapped() {\n code→save_settings;\n }\n }\n meta private;\n meta page;\n meta sync;\n}\n#BICBuYW1lICAa\ntable settings_view_page_data {\n type = \"Object\";\n persistent = false;\n}\n#Ofpos6ZVH8Uq4wNIrVcx6Oj5\naction save_settings() {\n $editor := @\\u267b→office_mix→current_editor;\n // The index of an activity is a unique number to reference it. The expected answer is optional and is used by Office Mix analytics.\n // Custom data is any data that you need while the app starts in View Mode. In this particular script, it is the `question` set by the user.\n $editor→set_input_activity(0, \"\", 1, data→settings→to_json);\n meta private;\n}\n#TyCJn9KTtksCY1nxdUpgB18L\naction load_settings() {\n $js := @\\u267b→office_mix→current_configuration(0);\n data→settings := records→Settings→create;\n if not $js→is_invalid then {\n data→settings→from_json($js);\n }\n else {\n code→default_settings;\n }\n meta private;\n}\n#XOVEmidye5OpPaWMlmI6njTk\naction default_settings() {\n // This is the sample question to be used if no configuration is provided in `Edit Mode`\n data→settings→question := \"Edit me to set the question\";\n meta private;\n meta sync;\n}\n#h2r1rbrbC280iZiz2Hvcq740 meta import office_mix {\n pub \"smola\"\n usage {\n type viewer\n type editor\n type choice\n action `async` slide_state(viewer: ♻ office_mix → viewer) returns(js: Json_Object)\n action `async` set_slide_state(viewer: ♻ office_mix → viewer, state: Json_Object)\n action `async` next_slide(viewer: ♻ office_mix → viewer)\n action `async` complete_simple_activity(viewer: ♻ office_mix → viewer, index: Number)\n action `async` current_viewer() returns(viewer: ♻ office_mix → viewer)\n action `async` connect()\n action `async` current_editor() returns(editor: ♻ office_mix → editor)\n action `sync` is_edit_mode() returns(b: Boolean)\n action `sync` is_connected() returns(connected: Boolean)\n action `sync` is_view_mode() returns(b: Boolean)\n action `async` current_configuration(index: Number) returns(js: Json_Object)\n action `async` set_simple_activity(editor: ♻ office_mix → editor, index: Number, custom_data: Json_Object)\n action `async` set_input_activity(editor: ♻ office_mix → editor, index: Number, answer: String, max_score: Number, custom_data: Json_Object)\n action `async` complete_input_activity(viewer: ♻ office_mix → viewer, index: Number, answer: String, score: Number, is_complete: Boolean)\n action `async` set_choice_activity(editor: ♻ office_mix → editor, index: Number, choices: Collection[ ♻ office_mix → choice], max_score: Number, custom_data: Json_Object)\n action `sync` create_choices(editor: ♻ office_mix → editor) returns(choices: Collection[ ♻ office_mix → choice])\n action `sync` add_choice(choices: Collection[ ♻ office_mix → choice], name: String, is_answer: Boolean)\n action `async` complete_choice_activity(viewer: ♻ office_mix → viewer, index: Number, answer: String_Collection, score: Number, is_complete: Boolean)\n action `async` start_attempt(viewer: ♻ office_mix → viewer, index: Number, type: String)\n action `async` add_hints(editor: ♻ office_mix → editor, index: Number, hints: String_Collection)\n action `async` get_hint(viewer: ♻ office_mix → viewer, index: Number, hint_index: Number) returns(hint: String)\n action `sync` is_run_locally() returns(b: Boolean)\n action `async` on_skip_slide(viewer: ♻ office_mix → viewer, @action: Action)\n }\n}\n", "fjsc": "meta version \"v2.2,js,ctx,refs,localcloud,unicodemodel,allasync\";\nmeta name \"faq\";\nmeta rootId \"NvlICz4I1I4g3L6rdvkN1Sb4\";\nmeta hasIds \"yes\";\nmeta platform \"current\";\nmeta parentIds \"\";\n// Frequently asked questions. #docs #faq\n#main\naction main() {\n #pfDKPZiTONFucbOz // {parentTopic:contents}\n #rKH7VYjeSZ5qTv4I // ### who created TouchDevelop\n #kWnrfxiKMJ4aYPsI // TouchDevelop is developed by the Research in Software Engineering group (RiSE) at Microsoft Research. [Learn more about our research...](http://research.microsoft.com/touchdevelop)\n #egrX5Ed4mYOl7Bth // ### why was TouchDevelop created\n #gEGMxxU9wvoQlver // We want to explore how the future of software development might look like when the most commonly accessible computing devices are mobile devices. We have found that TouchDevelop is a great way to learn or teach programming.\n #pmZW7gwSpCwvSeBk // ### what browsers and devices does TouchDevelop run on?\n #Gqsjd4PJ7qF7a0UK // The TouchDevelop Web App runs on [virtually all recent platforms](https://www.touchdevelop.com/platforms), including iPad, iPhone, Android (phones and tablets), Macs, PC. For the Windows Phone, you can download the [TouchDevelop app from the Windows Phone Store](http://windowsphone.com/s?appId=fe08ccec-a360-e011-81d2-78e7d1fa76f8).\n #bigUk0bn4RM2dCYR // ### does TouchDevelop replace other professional IDEs?\n #ohexDxybnieKiV0T // TouchDevelop has been designed for mobile devices with touchscreens. While it can also be used with keyboard and mouse, you still want to use professional development tools when you have the resources.\n #YWFFlzEAXfYkdY88 // ### how do I create Windows/Windows Phone/Android/iOS apps?\n #xdUdmLFEFOLeF1cA // Follow the instructions in [export to app](/exporttoapp).\n #xmTE4RGGcQR3sKzQ // ### what about the TouchDevelop Windows Phone app\n #PtmBA5LLot5CBSoc // The TouchDevelop Windows Phone app was the first to launch in April 2011. The TouchDevelop Web App Preview was launched in October 2012. Certain sensors and data providers that can be used in the TouchDevelop Windows Phone app and generated Windows 8 apps are not accessible on the web due to browser restrictions.\n #ojIFVLpIRq4h9Vxv // ### does TouchDevelop work offline?\n #Q5zmZEpbcPASdM4H // Yes! After you run the web app once, it will be cached on your device. [learn more...] (/offlinesupport)\n #NPgmp4E1zKDUWzci // ### how can I change the language of TouchDevelop?\n #jmGZ4cLweV6NmbgY // Go to your [account settings](/accountsettings) and change your preferred language. TouchDevelop is not yet localized in all languages so your mileage will vary.\n #RuC7HRkZBa31lEwn // ### does TouchDevelop work in my language?\n #f1cC43ALRBBO76r5 // TouchDevelop is partially localized. Help us localize TouchDevelop by playing the [localization game](http://touchdeveloptranslator.azurewebsites.net/)!\n #CaQzOPGewL8pVAUE // TouchDevelop will also automatically translate the help into your language using Microsoft Translator.\n #uVYmmkB4gCGsybvf // ### how was the TouchDevelop Web App created?\n #rWI2639IS1nEOZXu // The TouchDevelop Web App is written in Type Script. [Watch this video from the //build/ conference](http://channel9.msdn.com/Events/Build/2012/3-018) to learn more.\n #zMkQvwvtUNp76J2L // ### how do I report bugs or contact the TouchDevelop team?\n #ul12npnsSIJDd4AI // Tap on the `feedback` link on the lower right of this page.\n}\n", "gmaec": "meta version \"v2.2,js,ctx,refs,localcloud,unicodemodel,allasync,upperplex\";\nmeta name \"social coding\";\nmeta rootId \"BW5Z2tT8PGR2YDIgrAuEFSwo\";\nmeta allowExport \"yes\";\nmeta hasIds \"yes\";\nmeta platform \"current\";\nmeta parentIds \"\";\n// Understanding the script lifecycle in TouchDevelop #docs\n#VEa6LCnMw4ZByh2e\naction main() {\n #xBjWgS23MmRm2V8q // {parentTopic:contents}\n #TsSbdsjFrjlfbrl2 // {priority:18}\n #F3AeAVPtlABeBNH0 // TouchDevelop is a social coding platform where users can publish, fork, share their code freely.\n #NqBtxFlY9ixknwfz // ### script lifecycle\n #NNfJw34CNIpPxMKS // * [publishing scripts](/publishing)\n #D2ec4i8FUj8Zf42V // * [script udpates](/scriptupdates)\n #zatUDng4g32z2kw1 // * [script forks](/scriptforks)\n #worYh9j4YpqUkDjQ // * [pull requests](/pullrequests)\n #xBk0CTCjZwiUcwbn // * [](/groupscripts)\n #nTFmRh4k4iWbpFYt // * [how to search](/howtosearch)\n #hFLp36CMsiiqhnTC // ### community\n #WeNKI424s6V7W4kF // * [user score](/userscore)\n #t74MV1fKe6B4qWAO // * [user account](/useraccounts)\n #xAjOjHispoqafEHB // * [](/groups)\n #KKJEtnheKvaB9l3U // * [](/subscriptions)\n #ywJe2TIjeOzs8Qqn // * [](/insights)\n #EREwb2qLrQvylpAT // * [offline support](/offlinesupport)\n #HrlXZn0HuxSFDF8c // ### documentation\n #YCpaJ14DVX0dfFlw // * [add your own docs](/addyourowndocs)\n #xCtUVFwT2yTxkSyI // * [how to edit the docs](/howtoeditthedocs)\n}\n", "gnvi": "meta version \"v2.2,js,ctx\";\nmeta name \"theme\";\nmeta icon \"AlignLeft\";\nmeta color \"#ff9955bb\";\nmeta rootId \"pyxigTkgfxN2UU8WcngsVxr3\";\nmeta isLibrary \"yes\";\nmeta allowExport \"yes\";\nmeta platform \"current\";\n// Basic themes for boxes\naction title_1() {\n // Sets the current box to **title 1** style\n $m := 0.5;\n $font_size := 2;\n code→paragraph($m, $font_size, colors→foreground);\n}\naction paragraph(margins: Number, font_size: Number, foreground: Color) {\n box→set_margins($margins, $margins, $margins, $margins);\n box→set_font_size($font_size);\n box→set_text_wrapping(true, 15);\n box→set_foreground($foreground);\n if data→right_aligned then {\n box→set_horizontal_alignment(0, 1);\n }\n meta private;\n}\naction title_2() {\n // Sets the current box to **title 2** style\n $m := 0.5;\n $font_size := 1.5;\n code→paragraph($m, $font_size, colors→foreground);\n}\naction title_3() {\n // Sets the current box to **title 3** style.\n $m := 0.5;\n $font_size := 1.2;\n code→paragraph($m, $font_size, colors→foreground);\n}\naction subtle() {\n // Sets the current box to **subtle** style.\n $m := 0.5;\n $font_size := 1;\n code→paragraph($m, $font_size, colors→subtle);\n}\naction normal() {\n // Sets the current box to **normal** style\n $m := 0.5;\n $font_size := 1;\n code→paragraph($m, $font_size, colors→foreground);\n}\naction example() {\n if box→is_init then {\n skip;\n }\n if true then {\n // This library provides various built in themes to display structured paragraphs.\n // All text wrap by default.\n do box {\n code→huge;\n \"huge\" →post_to_wall;\n }\n do box {\n code→title_1;\n \"title 1\" →post_to_wall;\n }\n do box {\n code→title_2;\n \"title 2\" →post_to_wall;\n }\n do box {\n code→title_3;\n \"title 3\" →post_to_wall;\n }\n do box {\n code→normal;\n \"normal\" →post_to_wall;\n }\n do box {\n code→accent;\n \"accent\" →post_to_wall;\n }\n do box {\n code→subtle;\n \"subtle\" →post_to_wall;\n }\n }\n meta page;\n}\naction accent() {\n // Sets the current box to **accent** style.\n $m := 0.5;\n $font_size := 1;\n code→paragraph($m, $font_size, colors→accent);\n}\naction set_right_aligned(value: Boolean) {\n // Sets whether the next paragraphs should be right aligned.\n data→right_aligned := $value;\n}\nvar right_aligned : Boolean {\n}\naction huge() {\n // Sets the current box to **title 1** style\n $m := 0.5;\n $font_size := 5;\n code→paragraph($m, $font_size, colors→foreground);\n}\n", +"goale": "meta version \"v2.2,js,ctx,refs,localcloud,unicodemodel,allasync,upperplex\";\nmeta name \"blank engduino\";\nmeta icon \"CreditCard\";\nmeta color \"#ff00008b\";\nmeta rootId \"SEYbC35yczei4aI3wm7icdMs\";\nmeta iconArtId \"qmjzqlkc\";\nmeta allowExport \"yes\";\nmeta hasIds \"yes\";\nmeta platform \"current\";\nmeta parentIds \"\";\n// A blank Engduino v3 sketch. #arduino #arduinoSketch #Engduink\n#LnSjoBj2DrSx4mcw\naction setup() {\n #mQv6HDl3bdDDAJI0 skip;\n meta private;\n}\n#xq99yDlZpVBNRgrY\naction loop() {\n #xBK6GndqJnRSJkTx @\\u267b→engduino→set_all_LEDs(colors→random);\n #xtbigB2VPSstxCXs @\\u267b→engduino→delay(200);\n #OSTD49T6WAb9oYz6 @\\u267b→engduino→set_all_LEDs(colors→black);\n #jTiWi7fMT5Y0BSEk @\\u267b→engduino→delay(200);\n meta private;\n}\n#xdB9Cm8GWFKxZGcr\naction variables() {\n #khP9iYCJxRB2iUZw skip;\n meta private;\n}\n#Z2bgYR2Rs9Bvcb74\nvar screenshot : Picture {\n is\\_resource = true;\n url = \"https://az31353.vo.msecnd.net/pub/qmjzqlkc\";\n transient = true;\n}\n#eYLroh27IpYxvi8f meta import engduino {\n pub \"ornyc\"\n usage {\n\n action `async` set_LED(led_number: Number, color: Color)\n action `async` millis() returns(ms: Number)\n action `async` micros() returns(us: Number)\n action `async` button_pressed() returns(b: Boolean)\n action `async` button_was_pressed() returns(b: Boolean)\n action `async` delay(millis: Number)\n action `async` acceleration() returns(p: Vector3)\n action `async` temperature() returns(p: Number)\n action `async` set_all_LEDs(color: Color)\n }\n #ynl5rsn8THHTsDiJ resolve arduino = ♻ arduino with {\n }\n}\n#uvXS88LcuackBUtZ\naction main() {\n #EuO57UhnSOMDRRlU // This action emulates the code loop in the bug and will not be compiled.\n #Lo714zCo2ze5KJxO code→setup;\n #rTWfhzlllMzajBW8 while true do {\n #xASbcNy6sOwDn24U code→loop;\n }\n}\n#xEqnQPX6C7o8xLVl meta import arduino {\n pub \"cqfda\"\n usage {\n\n action `sync` digital_read(pin: Number) returns(bit: Number)\n action `sync` digital_write(pin: Number, value: Number)\n action `sync` analog_read(pin: Number) returns(bit: Number)\n action `sync` analog_write(pin: Number, value: Number)\n action `async` pin_mode(pin: Number, mode: Number)\n action `sync` HIGH() returns(v: Number)\n action `sync` LOW() returns(v: Number)\n action `sync` OUTPUT() returns(v: Number)\n action `sync` INPUT() returns(v: Number)\n action `async` delay(millis: Number)\n action `sync` sketch(source: String)\n action `sync` static_buffer(bytes: String) returns(buf: Buffer)\n action `sync` INPUT\\_PULLUP() returns(v: Number)\n action `sync` LED\\_BUILTIN() returns(r: Number)\n action `sync` mac(address: String)\n action `sync` analog_reference(type: Number)\n action `sync` DEFAULT() returns(r: Number)\n action `sync` EXTERNAL() returns(r: Number)\n action `sync` tone(pin: Number, frequency: Number, duration: Number)\n action `sync` no_tone(pin: Number)\n action `sync` millis() returns(millis: Number)\n action `sync` micros() returns(micros: Number)\n action `sync` pulse_in(pin: Number, value: Number, timeout: Number) returns(micros: Number)\n action `sync` board(name: String)\n action `sync` print_value(name: String, value: Number)\n action `sync` print(text: String)\n action `sync` println(text: String)\n action `sync` map(value: Number, from_low: Number, from_high: Number, to_low: Number, to_high: Number) returns(r: Number)\n action `sync` constrain(value: Number, a: Number, b: Number) returns(r: Number)\n action `async` delay_microseconds(micros: Number)\n }\n}\n", "gtfla": "meta version \"v2.2,js,ctx,refs,localcloud,unicodemodel,allasync\";\nmeta name \"blank cordova library\";\nmeta icon \"ApproveButton\";\nmeta color \"#ffe3256b\";\nmeta rootId \"yGFW3wy9mcuwDt2lxN2XzLPS\";\nmeta isLibrary \"yes\";\nmeta allowExport \"yes\";\nmeta hasIds \"yes\";\nmeta platform \"accelerometer,compass,gyroscope,location,musicandsounds,network,orientation,phone,cordova\";\nmeta parentIds \"\";\n// A library that wraps an Apache cordova plugin #cordova\n#xbyRT3U8tTYlJuX3\naction init(#qC2ALk0kurvg43d9 options\\u003f: * Options) {\n #MNkyanFCYYm1mj2c // Initializes the plugin. Call once.\n #X4G0I6zR3PXSOoW2 contract→requires(data→logger→is_invalid, \"plugin already initialized\");\n #t7IXp9pyue4DKV3r app→import(\"cordova\", \"TODO: cordoval plugin name here\", \"*\");\n #pAoVhCYiE8wIBNx2 data→logger := app→create_logger(\"mylib\");\n #x5295YzyzYEkwRz9 // TODO: use `app-> javasctipt` and `app->javascript async` to proxy with javascript.\n #NSEi48Fc3E82Gzhc // TODO: change the script description\n #xGNJXaGae2QQzC4o // TODO: write docs in `code-> example`\n}\n#SHXfYJBDaSY28xmP\nvar logger : App_Logger {\n transient = true;\n}\n#BdGhpbmca\ntable Options {\n type = \"Object\";\n exported = true;\n persistent = false;\n}\n#M64FUpLsIJLTUj44\naction example() {\n #HaX1MKDnbGBzPPnq // Document your library here!\n meta private;\n meta sync;\n}\n", "ibksb": "meta version \"v2.2,js,ctx,refs,localcloud,unicodemodel,allasync\";\nmeta name \"blank node library\";\nmeta icon \"ArrowStandardCircle\";\nmeta color \"#ff007fff\";\nmeta rootId \"yGFW3wy9mcuwDt2lxN2XzLPS\";\nmeta isLibrary \"yes\";\nmeta allowExport \"yes\";\nmeta hasIds \"yes\";\nmeta platform \"network,npm,shell\";\nmeta parentIds \"\";\n// A library that wraps a npm module #node #npm #azure\n#xbyRT3U8tTYlJuX3\naction init(#qC2ALk0kurvg43d9 options\\u003f: * Options) {\n #MNkyanFCYYm1mj2c // Initializes the library. Call this action from your ``_init`` function.\n #t7IXp9pyue4DKV3r app→import(\"npm\", \"TODO: npm package name here\", \"*\");\n #pAoVhCYiE8wIBNx2 data→logger := app→create_logger(\"TODO: mylib\");\n #PUrP48D9R04LP8ev // TODO: use `app-> server setting` to read environment variables or node command line arguments.\n #x5295YzyzYEkwRz9 // TODO: use `app-> javasctipt` and `app->javascript async` to proxy with javascript.\n #fNRnVruS6cg7D9H3 // TODO: write some unit tests!\n #xlb7m4Eyw0BWFbzP // TODO: change the script description\n #s4LqDBpWVhF4APDU // TODO: write the docs in `code-> example`\n}\n#SHXfYJBDaSY28xmP\nvar logger : App_Logger {\n transient = true;\n}\n#BdGhpbmca\ntable Options {\n type = \"Object\";\n exported = true;\n persistent = false;\n}\n#egka9cxvzrsZcSyc\naction example() {\n #xbnNQHjvSDNjeKCB // Document your library here!\n #CHb8jtuTrMd1PuMI // {imports}\n meta private;\n meta sync;\n}\n", "igzu": "meta version \"v2.2,js,ctx,refs,localcloud,unicodemodel,allasync,upperplex\";\nmeta name \"game animations\";\nmeta icon \"Controller\";\nmeta color \"#ff9955bb\";\nmeta rootId \"x5GWly5akgFmjLrYRRLK4cEP\";\nmeta isLibrary \"yes\";\nmeta hasIds \"yes\";\nmeta platform \"current\";\nmeta parentIds \"\";\n// A suite of nifty game animations.\n#example\naction example() {\n #oQvXum6wlCxvA14x // This library provides a bunch of cool animation to be used with the `libs->game` library.\n #OrK2keevME4R7Ikt // {hide}\n #IBkRy8dLlysml6xn $pic := media→create_picture(480, 800);\n #LUD4QUQWDq3cZvhL $board := @\\u267b→game→start;\n #PcO7yRSD4Y6NqNK1 @\\u267b→game→bounce_on_sides;\n #uuxlVRt3Fj7zUX3d $sprite := $board→create_rectangle(100, 100);\n #WeOMvS436zFINcmB $sprite→set_color(colors→blue);\n #cd8qQ2IGGEG8LSik $sprite→set_acceleration_y(400);\n #ozsU7Yocpctcf8Kz $sprite→set_opacity(0.8);\n #OTQ8K19QPPnhEckE // {/hide}\n #EBms12UX1I3YptSc // ### splatter\n #o4uCUnbQ4qtH4xOe // Display a splatter under the sprite that goes away after a couple secs.\n #pQPunYKP94mwyJYM code→splatter($sprite, $pic);\n #ItG0lTW3p7NiLMvc // ### add score to a sprite\n #WTbMbwwzr2UNA7NT // Add a score that pops a little ``+score`` on the top right corner of the sprite.\n #Ejn7ZLQa7j8Earpj code→add_score($sprite, 100);\n meta private;\n meta test;\n}\n#MHC9cku1GTEdncGR meta import game {\n pub \"sduub\"\n usage {\n action `sync` set_score(value: Number)\n action `async` set_life(value: Number)\n action `sync` start_timer()\n action `sync` start_countdown_timer(seconds: Number)\n action `sync` life() returns(r: Number)\n action `sync` score() returns(r: Number)\n action `sync` current_time() returns(seconds: Number)\n action `sync` add_score(value: Number)\n action `async` add_life(value: Number)\n action `sync` clear_timer()\n action `async` remove_life(value: Number)\n action `async` end()\n action `async` start() returns(board: Board)\n action `sync` reset()\n action `async` start_with_fixed_size(width: Number, height: Number) returns(board: Board)\n action `async` start_with_background_picture(pic: Picture) returns(board: Board)\n action `sync` board() returns(board: Board)\n action `sync` on_end(@action: Action)\n action `async` splash_text(message: String, seconds: Number, foreground: Color, background: Color, done: Action)\n action `async` start_landscape() returns(board: Board)\n action `async` start_portrait() returns(board: Board)\n action `sync` set_hud_colors(life: Color, timer: Color, score: Color)\n action `sync` hud_sprites() returns(sprites: Sprite_Set)\n action `async` life_visible() returns(b: Boolean)\n action `async` set_life_visible(visible: Boolean)\n action `sync` sprites() returns(sprites: Sprite_Set)\n action `async` set_background_scene(direction: String, pic: Picture)\n action `sync` bounce_on_sides()\n action `sync` create_sprite(pic: Picture) returns(sprite: Sprite)\n }\n}\n#IgJeOaT4qD6XCDWM\naction splatter(#xSZvm6EeJuCvT4s4 sprite: Sprite, #MCvt1zYjYJcK4L44 splatter: Picture) {\n #X4OAdwxnO5wHxDZa // Splats the ``splatter`` picture under the ``sprite`` and fades it away.\n #X64Ps5YYS1av5MpI $sp := @\\u267b→game→board→create_picture($splatter);\n #ODXoYXN95HMQR2Cl $sp→set_pos($sprite→x, $sprite→y);\n #u9qh43UUwoK0FZl0 $sp→set_width($sprite→width);\n #x2LYMGKCfJ1oW8qz $sp→set_speed($sprite→speed_x / 5, $sprite→speed_y / 5);\n #uAJdLNuxiNbu2T4D $sp→friction := 0.05;\n #xkBOKjaSeL4oRcyl $sp→z_index := $sprite→z_index - 1;\n #F7VCHbHecTaVIjT4 $anim := $sp→create_animation;\n #IUYXcNBxhS2fVVRG $anim→puff_out(0.6, \"cubic\", 1.2);\n #bx6onFKBhqu1SI15 $anim→delete;\n}\n#v4ugzdtO8BJPkkj4\naction add_score(#wysUeGszNWAN7trp sprite: Sprite, #tEL2GDgDi86bI72e score: Number) {\n #VeUaeIa25nApnqQT // Shows a little score animation\n #NxnWqSc1zhnO54N9 $bonus := @\\u267b→game→board→create_text(100, 20, 15, $score→to_string);\n #DdGj3W3NCt2n0PVo if $score > 0 then {\n #jIysyn2MjoPyhGQY $bonus→set_text(\"+\" ∥ $bonus→text);\n #dyvGOVwl5E8c2rkE $bonus→set_color(colors→orange);\n }\n else {\n #FMAzDAxm7WBKyVi5 $bonus→set_color(colors→red);\n }\n #VyMLdyfovccmoVPZ $bonus→fit_text;\n #s9mf7tHP4hg6zQrA $bonus→set_pos($sprite→right, $sprite→@top + $bonus→height * 0.6);\n #lU46vyX425TKrBrI $bonus→set_color(colors→green);\n #wGW2fYDAlMw9MmgM @\\u267b→game→add_score($score);\n #trQhQdUjt6fA4cos $anim := $bonus→create_animation;\n #zz6SU1LbMkxhFiv2 $anim→fork→fade_out(1.5, \"linear\");\n #aQP47O58Ny55MN92 $anim→move_to(1.5, \"linear\", \"inout\", $bonus→x, $bonus→y - $sprite→height / 2);\n #IWdqhz1GYoeIezqg $anim→delete;\n meta sync;\n}\n#xkUbqdD2nTGw2md2\naction demo() {\n #nKfBY2pfuGzl6Lqa $pic := media→create_picture(480, 800);\n #umREhXlH6l4zWsW1 $pic→clear(colors→green);\n #c4OOPp4yjrTumwFn $board := @\\u267b→game→start;\n #xC9EjUCuAFD2OizM @\\u267b→game→bounce_on_sides;\n #HTWzkiDs2iFrpskf $sprite := $board→create_rectangle(100, 100);\n #bzn6oVDiFRefDYp2 $sprite→set_color(colors→blue);\n #xYGC7i8OXtlJa6Do $sprite→set_acceleration_y(400);\n #JLsA8cmWdwlhqyVQ $sprite→set_opacity(0.8);\n #r5ErvAs4SbRUQw7y $sprite→on_tap($tapped);\n #ReFgA1ac1h6CUcqH where tapped(x: Number, y: Number) {\n #V34hkhzTxtRXuf22 code→splatter($sprite, $pic);\n #xdmQ7YIokLC3Enu3 code→add_score($sprite, 100);\n }\n meta private;\n meta test;\n}\n#FEj2rviL4TuENW1u\naction puff(#K0dT3erQY946Qikv sprite: Sprite) {\n #wL61RR1dWtwBzsUz // Create a little puff out animation\n #gS3roQKn8OtmLwfZ $pf := @\\u267b→game→board→create_ellipse($sprite→width, $sprite→height);\n #FQE8wIG8gSPhzKob $pf→x := $sprite→x;\n #vTXyJ2Ydw2QPjMzV $pf→y := $sprite→y;\n #K0hkpaxIGOKgRCn1 $anim := $pf→create_animation;\n #AYo2HSiJ936KQfIR $anim→puff_out(0.5, \"cubic\", 1.5);\n #xeDEZFLy319oNVtY $anim→delete;\n}\n", @@ -33,6 +32,7 @@ "parp": "meta version \"v2.2,js,ctx,refs,localcloud,unicodemodel,allasync\";\nmeta name \"blank turtle\";\nmeta icon \"Snowflake\";\nmeta color \"#ff007fff\";\nmeta rootId \"JfhbuKHwe3K29WLENfXE17iC\";\nmeta allowExport \"yes\";\nmeta hasIds \"yes\";\nmeta platform \"current\";\nmeta parentIds \"\";\n// #turtle\n#k3GG7tZEQiPXLEm5bnyfOkDF\naction main() {\n #iTGtxXhIwXwHLfFT @\\u267b→turtle→forward(100);\n}\n#xEv66n448mkvLMp4 meta import turtle {\n pub \"smzqa\"\n usage {\n type Maze\n action `async` pen_down()\n action `async` pen_up()\n action `async` move_to(x: Number, y: Number)\n action `async` forward(steps: Number)\n action `async` left_turn(angle: Number)\n action `async` set_pen_color(c: Color)\n action `async` xcor() returns(x: Number)\n action `async` ycor() returns(y: Number)\n action `async` heading() returns(a: Number)\n action `async` world_width() returns(w: Number)\n action `async` world_height() returns(h: Number)\n action `async` set_heading(angle: Number)\n action `async` set_pen_size(thickness: Number)\n action `async` right_turn(angle: Number)\n action `async` circle(radius: Number)\n action `async` world_board() returns(board: Board)\n action `async` turn_to(dx: Number, dy: Number)\n action `async` world_picture() returns(pic: Picture)\n action `async` set_speed(steps_per_second: Number)\n action `async` go_home()\n action `async` back(steps: Number)\n action `async` pen_size() returns(size: Number)\n action `async` clean()\n action `async` clear_screen()\n action `async` speed() returns(v: Number)\n action `async` set_xy(xcor: Number, ycor: Number)\n action `async` set_x(xcor: Number)\n action `async` set_y(ycor: Number)\n action `async` pen_color() returns(c: Color)\n action `async` color_under() returns(c: Color)\n action `async` save_picture()\n action `async` xy() returns(x: Number, y: Number)\n action `async` touch_xy() returns(tx: Number, ty: Number)\n action `async` grid()\n action `async` fast()\n action `async` stamp()\n action `async` set_turtle_picture(pic: Picture)\n action `async` set_turtle_opacity(opacity: Number)\n action `async` trail()\n action `async` add_obstacle(maze: ♻ turtle → Maze, x: Number, y: Number, width: Number, height: Number, c: Color)\n action `async` set_goal(maze: ♻ turtle → Maze, x: Number, y: Number, radius: Number, c: Color)\n action `async` maze() returns(maze: ♻ turtle → Maze)\n action `async` lock(maze: ♻ turtle → Maze)\n action `async` history() returns(commands: String)\n action `async` clear_history()\n action `sync` on_command(command: Text_Action)\n action `async` add_way_point(maze: ♻ turtle → Maze)\n action `async` on_collision(maze: ♻ turtle → Maze, collision: Action)\n }\n}\n", "qdzr": "meta version \"v2.2,js,ctx,refs,localcloud,unicodemodel,allasync,upperplex\";\nmeta name \"blank event hubs\";\nmeta icon \"Stacks\";\nmeta color \"#ffffffff\";\nmeta rootId \"rTo1i2UE9ZqDVMIBTLAUqMYl\";\nmeta iconArtId \"wyfreugv\";\nmeta isLibrary \"yes\";\nmeta allowExport \"yes\";\nmeta isCloud \"yes\";\nmeta hasIds \"yes\";\nmeta platform \"network,npm,shell\";\nmeta parentIds \"\";\n// A node.js web site that sends events to Azure Event Hubs using AMQP. #node #azure #restify #rest #api\n#x6T4YCsBsZWtPUmF\naction \\_init() {\n #Zy8rc2YHRBIcmnOf // This template allows you to easily stream data to an Azure Event Hubs instance using the AMQP1.0 protocol.\n #LKpR3HLsnUt8zjTC // To setup this service, you will have to setup the following:\n #x0DCfAxIkDRE4kH5 // * An [Event Hub](http://azure.microsoft.com/en-us/services/event-hubs/) in Azure.\n #BPgmHhKMscVJieMa // * define the ``AZURE_SERVICEBUS_SAS_KEY_NAME`` environment variable with your SAS key name\n #R7tTfXVWqjfIjJuw // * define the ``AZURE_SERVICEBUS_SAS_KEY`` environment variable with the SAS key.\n #uHkwReQVwrICaHzH // * (optional) setup application insights instrumentation key by defining the ``APPINSIGHTS_INSTRUMENTATION_KEY`` environment variable.\n #JGUzkYMjc2rxbxQ2 // * `[Export]` this script to a node.js web site.\n #bMtNnag4oaUSbmG8 data→logger := app→create_logger(\"api\");\n #ggtkH2QPjkFSMATl code→init_restify;\n #xYi50zyUUbDrUiYA code→init_azure_services;\n #GmpMiJN3N0hJ473p // TODO: change the event hubname below\n #A3exv4u2E6ZcTY5F data→hub := @\\u267b→azure_event_hubs→create_event_hub_if_not_exists(\"events\");\n #rlP2tbcbetF1rUVe time→run_every(1, $perform);\n #OVfCshDzbjMrMcel where perform() {\n #wjsvsYZW73p1LRfD // this is where you read your sensor data\n #xViWmNVnfqeTVF3p $msg := records→Message→create;\n #hzLc4iJcGXm7Yk3P $msg→temp := math→random(1000);\n #T9qIzqSC0FK3USRu // and send it to the event hub...\n #uX42zx1Jbgxuczbb data→hub→send_message_as_json(data→deviceid, $msg→to_json);\n }\n}\n#yjW8JMhhkCVxVG9z meta import parallel {\n pub \"fncvb\"\n usage {\n type queue\n action `async` @for(count: Number, @action: Number_Action)\n action `async` for_batched(count: Number, batch_count: Number, item_action: Number_Action, batch_action: Action)\n action `sync` schedule(q: ♻ parallel → queue, task: Action)\n action `sync` create_queue(max_running: Number) returns(queue: ♻ parallel → queue)\n action `async` wait_for_empty(q: ♻ parallel → queue)\n action `async` for_json(js: Json_Object, @action: Json_Action)\n }\n}\n#kGiIbArLBJgrGrUh\nvar logger : App_Logger {\n transient = true;\n}\n#xht4tB8QBEGYhcxd\naction init_azure_services() {\n #zoRhW6H8Xjlu4Nfv @\\u267b→application_insights→init;\n #xrdwLuCApP4dSbPN @\\u267b→azure_event_hubs→init;\n #rIelx44MT4mxwsuP if data→deviceid→is_empty then {\n #lVuKP04Sv0BPFvTe data→deviceid := @\\u267b→node_crypto→random_bytes(16)→to_string(\"hex\");\n }\n #SqiRrk2SBmwfUygc data→logger→info(\"deviceid: \" ∥ data→deviceid);\n meta private;\n}\n#VJhyWCgHgpoXBxQe\naction init_restify() {\n #Rfk2zOUWd63utX0c $server := @\\u267b→restify→server;\n #xwHqz4BboMG6fFYA $server→use(@\\u267b→restify→authorization_parser);\n #CCiEC9MjVyBu1Alm $server→pre(@\\u267b→restify→sanitize_path);\n #QhDtswBtwpK4HWfj $throttle := @\\u267b→restify→throttle;\n #xnNL4UkM1HGz7bML where rate := 40;\n #pjHy3CkNNDrbTRdj where burst := 100;\n #u8A4y4yHMKc8lyUK where ip := true;\n #hivZ6Vt6ftjQnefM $server→use($throttle);\n #xHYwcSAiT7KduHhg $server→use(@\\u267b→restify→CORS);\n #uouNso31DPAdpy0R $server→use(@\\u267b→restify→body_parser);\n #PQsbPK8j0KxXP7BN $server→use(@\\u267b→restify→gzip_response);\n #krhauhLHNWLfS4Rr $server→use(@\\u267b→restify→query_parser);\n #OQV2aOnQMrFwfSMH $server→use(@\\u267b→restify→conditional_request);\n #dJCZRF6m52AEcGvh @\\u267b→restify_touchdevelop→autobind($server);\n #RheHhoSGEfw2gVg7 code→init_routes;\n #JCEJ0pDtVdSmeI23 $server→use(@\\u267b→restify_touchdevelop→errors_to_log(data→logger));\n meta private;\n}\n#RtmLKYphNIzdwos1 meta import restify {\n pub \"uqffa\"\n usage {\n action `async` `type` Request_Handler(req: ♻ restify → Request, res: ♻ restify → Response)\n #xLPhdjOebDT8w77X\n table Throttle_Options {\n type = \"Object\";\n exported = true;\n persistent = false;\n fields {\n #xo6LfV0hyAQtz675 rate : Number\n #yZ2QZAfeW3W74JA1 burst : Number\n #JUlNvDq7Hm9cTUAG ip : Boolean\n #w2h4dcf4I5K5h7kn xff : Boolean\n #RO3Sx6iTt4WsVBm6 username : Boolean\n #VbsYnDvr3t4Xr4VA maxKeys : Number\n #w25h9R5LKJnWiBNu tokensTable : ♻ restify → Tokens_Table\n }\n }\n #xdeuBx505IsZ6eEI\n table Serve_Static_Options {\n type = \"Object\";\n exported = true;\n persistent = false;\n fields {\n #NfWLVJBBbHvtMqkl default : String\n #KvIMj1sEoAwQCf22 maxAge : Number\n }\n }\n #mqEMUbizkEp6naSD\n table CORS_Options {\n type = \"Object\";\n exported = true;\n persistent = false;\n fields {\n #xMYYV6C3eS7PWsfQ origins : String\n #z5HdpFdSi792e1OX credentials : Boolean\n #Fw1D0A9ZfeMCf5c3 headers : String\n }\n }\n #w2zTzWkfMf01yOko\n table Body_Parser_Options {\n type = \"Object\";\n exported = true;\n persistent = false;\n fields {\n #mhaHCLobgUgMrv72 maxBodySize : Number\n #xr4fKleNd4wHHP1l mapParams : Boolean\n #st0ir2vLTxbLTQWB mapFiles : Boolean\n #z5ah2mZWb8c5FmTM overrideParams : Boolean\n }\n }\n #xv4yZciZi2wFoqpM\n table Send_Options {\n type = \"Object\";\n exported = true;\n persistent = false;\n fields {\n #svWYln7UIackFIpB status : Number\n }\n }\n #BVGhpbmca\n table HTTP_Status_Codes {\n type = \"Object\";\n exported = true;\n persistent = false;\n fields {\n #BVGhpbmcaMjAwIE9L @200_OK : Number\n #BVGhpbmcaMjAxIENyZWF0ZWQa @201_Created : Number\n #BVGhpbmcaMzAwIE11bHRpcGxlIENob2ljZXMa @300_Multiple_Choices : Number\n #BVGhpbmcaMzAxIE1vdmVkIFBlcm1hbmVudGx5 @301_Moved_Permanently : Number\n #BVGhpbmcaMzAyIE1vdmVkIFRlbXBvcmFyaWx5 @302_Moved_Temporarily : Number\n #BVGhpbmcaMzAzIFNlZSBPdGhlcgaa @303_See_Other : Number\n #BVGhpbmcaMzA0IE5vdCBNb2RpZmllZAaa @304_Not_Modified : Number\n #BVGhpbmcaMzA3IFRlbXBvcmFyeSBSZWRpcmVjdAaa @307_Temporary_Redirect : Number\n #BVGhpbmcaNDAwIEJhZCBSZXF1ZXN0 @400_Bad_Request : Number\n #BVGhpbmcaNDAxIFVuYXV0aG9yaXplZAaa @401_Unauthorized : Number\n #BVGhpbmcaNDAyIFBheW1lbnQgUmVxdWlyZWQa @402_Payment_Required : Number\n #BVGhpbmcaNDAzIEZvcmJpZGRlbgaa @403_Forbidden : Number\n #BVGhpbmcaNDA0IE5vdCBGb3VuZAaa @404_Not_Found : Number\n #BVGhpbmcaNDA1IE1ldGhvZCBOb3QgQWxsb3dlZAaa @405_Method_Not_Allowed : Number\n #BVGhpbmcaNDA4IFJlcXVlc3QgVGltZW91dAaa @408_Request_Timeout : Number\n #BVGhpbmcaNDA5IENvbmZsaWN0 @409_Conflict : Number\n #BVGhpbmcaNDEwIEdvbmUa @410_Gone : Number\n #BVGhpbmcaNDEyIFByZWNvbmRpdGlvbiBGYWlsZWQa @412_Precondition_Failed : Number\n #BVGhpbmcaNDEzIFJlcXVlc3QgRW50aXR5IFRvbyBMYXJnZQaa @413_Request_Entity_Too_Large : Number\n #BVGhpbmcaNDE1IFVuc3VwcG9ydGVkIE1lZGlhIFR5cGUa @415_Unsupported_Media_Type : Number\n #BVGhpbmcaNDE4IEltIGEgdGVhcG90 @418_Im_a_teapot : Number\n #BVGhpbmcaNDIyIFVucHJvY2Vzc2FibGUgRW50aXR5 @422_Unprocessable_Entity : Number\n #BVGhpbmcaNDIzIExvY2tlZAaa @423_Locked : Number\n #BVGhpbmcaNDI0IEZhaWxlZCBEZXBlbmRlbmN5 @424_Failed_Dependency : Number\n #BVGhpbmcaNDI1IFVub3JkZXJlZCBDb2xsZWN0aW9u @425_Unordered_Collection : Number\n #BVGhpbmcaNDI5IFRvbyBNYW55IFJlcXVlc3Rz @429_Too_Many_Requests : Number\n #BVGhpbmcaNTAwIEludGVybmFsIFNlcnZlciBFcnJvcgaa @500_Internal_Server_Error : Number\n #BVGhpbmcaNTAxIE5vdCBJbXBsZW1lbnRlZAaa @501_Not_Implemented : Number\n #BVGhpbmcaNTAzIFNlcnZpY2UgVW5hdmFpbGFibGUa @503_Service_Unavailable : Number\n }\n }\n type Request\n type Response\n type Tokens_Table\n type Server\n type Middleware\n type Error\n action `sync` use(server: ♻ restify → Server, mid: ♻ restify → Middleware)\n action `sync` get(server: ♻ restify → Server, path: String, @then: ♻ restify → Request_Handler)\n action `sync` post(server: ♻ restify → Server, path: String, @then: ♻ restify → Request_Handler)\n action `sync` server() returns(server: ♻ restify → Server)\n action `sync` send(res: ♻ restify → Response, content: String, options\\u003f: ♻ restify → Send_Options)\n action `sync` status(res: ♻ restify → Response, status: Number)\n action `sync` is(req: ♻ restify → Request, type: String) returns(r: Boolean)\n action `sync` accepts(req: ♻ restify → Request, types: String) returns(type: String)\n action `sync` put(server: ♻ restify → Server, path: String, @then: ♻ restify → Request_Handler)\n action `sync` del(server: ♻ restify → Server, path: String, @then: ♻ restify → Request_Handler)\n action `sync` head(server: ♻ restify → Server, path: String, @then: ♻ restify → Request_Handler)\n action `sync` pre(server: ♻ restify → Server, mid: ♻ restify → Middleware)\n action `sync` CORS(options\\u003f: ♻ restify → CORS_Options) returns(mid: ♻ restify → Middleware)\n action `sync` conditional_request() returns(mid: ♻ restify → Middleware)\n action `sync` route(server: ♻ restify → Server, method: String, path: String, @then: ♻ restify → Request_Handler)\n action `sync` json(res: ♻ restify → Response, content: Json_Object, options\\u003f: ♻ restify → Send_Options)\n action `sync` next(res: ♻ restify → Response)\n action `sync` next_error(res: ♻ restify → Response, error: ♻ restify → Error)\n action `sync` address(server: ♻ restify → Server) returns(address: String)\n action `sync` gzip_response() returns(mid: ♻ restify → Middleware)\n action `sync` header(req: ♻ restify → Request, name: String) returns(value: String)\n action `sync` is_secure(req: ♻ restify → Request) returns(r: Boolean)\n action `sync` is_chunked(req: ♻ restify → Request) returns(r: Boolean)\n action `sync` is_keep_alive(req: ♻ restify → Request) returns(r: Boolean)\n action `sync` set_header(res: ♻ restify → Response, name: String, value: String)\n action `sync` body_parser(options\\u003f: ♻ restify → Body_Parser_Options) returns(mid: ♻ restify → Middleware)\n action `sync` throttle(options\\u003f: ♻ restify → Throttle_Options) returns(middleware: ♻ restify → Middleware)\n action `sync` date_parser(clock_skew: Number) returns(middleware: ♻ restify → Middleware)\n action `sync` serve_static(directory: String, options\\u003f: ♻ restify → Serve_Static_Options) returns(middleware: ♻ restify → Middleware)\n action `sync` query_parser() returns(middleware: ♻ restify → Middleware)\n action `sync` authorization_parser() returns(middleware: ♻ restify → Middleware)\n action `sync` jsonp() returns(middleware: ♻ restify → Middleware)\n action `sync` body_as_json(req: ♻ restify → Request) returns(body: Json_Object)\n action `sync` id(req: ♻ restify → Request) returns(id: String)\n action `sync` param(req: ♻ restify → Request, name: String) returns(value: String)\n action `sync` opts(server: ♻ restify → Server, path: String, @then: ♻ restify → Request_Handler)\n action `sync` patch(server: ♻ restify → Server, path: String, @then: ♻ restify → Request_Handler)\n action `sync` to_string(ser: ♻ restify → Server) returns(s: String)\n action `sync` sanitize_path() returns(middleware: ♻ restify → Middleware)\n action `sync` body(req: ♻ restify → Request) returns(body: String)\n action `sync` send_error(res: ♻ restify → Response, status: Number, message: String)\n action `sync` all(server: ♻ restify → Server, @then: ♻ restify → Request_Handler)\n action `sync` method(req: ♻ restify → Request) returns(method: String)\n action `sync` url(req: ♻ restify → Request) returns(url: String)\n action `sync` query(req: ♻ restify → Request) returns(query: Json_Object)\n action `sync` redirect(res: ♻ restify → Response, status_code: Number, url: String)\n action `sync` send_status(res: ♻ restify → Response, status_code: Number)\n action `sync` charset(res: ♻ restify → Response, encoding: String)\n action `sync` route_regex(server: ♻ restify → Server, method: String, path_regex: String, @then: ♻ restify → Request_Handler)\n action `async` read_body_as_buffer(req: ♻ restify → Request) returns(body: Buffer)\n action `sync` headers(req: ♻ restify → Request) returns(headers: Json_Object)\n action `sync` server_url(req: ♻ restify → Request) returns(url: String)\n action `sync` html(res: ♻ restify → Response, content: String, options\\u003f: ♻ restify → Send_Options)\n action `sync` send_text(res: ♻ restify → Response, content: String, content_type: String, options\\u003f: ♻ restify → Send_Options)\n action `sync` send_buffer(res: ♻ restify → Response, content: Buffer, content_type: String, options\\u003f: ♻ restify → Send_Options)\n action `sync` finished(res: ♻ restify → Response) returns(done: Boolean)\n action `sync` http() returns(codes: ♻ restify → HTTP_Status_Codes)\n }\n}\n#A3d3ZvbSo4doxSON meta import restify_touchdevelop {\n pub \"dvuhb\"\n usage {\n action `sync` autobind(server: ♻ restify → Server)\n action `sync` errors_to_log(logger: App_Logger) returns(middleware: ♻ restify → Middleware)\n }\n #Ndi4Jc7GXTkHfWcQ resolve restify = ♻ restify with {\n }\n}\n#rMIDyd4TDaMKCuVx\naction init_routes() {\n #JtHQs8S4PNExhJqH skip;\n meta private;\n}\n#vOmAlM8jBeSaiHx8 meta import node_crypto {\n pub \"oevpc\"\n usage {\n type credentials\n type hash\n type hmac\n type cipher\n type decipher\n type sign\n type verify\n type DiffieHellman\n action `sync` get_ciphers() returns(ciphers: Collection[String])\n action `sync` get_hashes() returns(hashes: Collection[String])\n action `sync` create_credentials(details: Json_Object) returns(credentials: ♻ node_crypto → credentials)\n action `sync` create_hash(algorithm: String) returns(hash: ♻ node_crypto → hash)\n action `sync` update_hash(hash: ♻ node_crypto → hash, hash_data: Buffer)\n action `sync` digest_hash(hash: ♻ node_crypto → hash) returns(digest: Buffer)\n action `sync` update_hmac(hmac: ♻ node_crypto → hmac, hmac_data: Buffer)\n action `sync` digest_hmac(hmac: ♻ node_crypto → hmac) returns(digest: Buffer)\n action `sync` create_cipher(algorithm: String, password: Buffer) returns(cipher: ♻ node_crypto → cipher)\n action `sync` create_cipher_iv(algorithm: String, key: Buffer, iv: Buffer) returns(iv_cipher: ♻ node_crypto → cipher)\n action `sync` update_cipher(cipher: ♻ node_crypto → cipher, _data: Buffer) returns(enciphered: Buffer)\n action `sync` final(cipher: ♻ node_crypto → cipher) returns(cipher_final: Buffer)\n action `sync` set_auto_padding(cipher: ♻ node_crypto → cipher)\n action `sync` create_decipher(algorithm: String, password: Buffer) returns(decipher: ♻ node_crypto → decipher)\n action `sync` create_decipher_iv(algorithm: String, key: Buffer, iv: Buffer) returns(iv_decipher: ♻ node_crypto → decipher)\n action `sync` update_decipher(decipher: ♻ node_crypto → decipher, _data: Buffer) returns(deciphered: Buffer)\n action `sync` final_(decipher: ♻ node_crypto → decipher) returns(decipher_final: Buffer)\n action `sync` set_auto_padding_(decipher: ♻ node_crypto → decipher)\n action `sync` create_sign(algorithm: String) returns(sign: ♻ node_crypto → sign)\n action `sync` update_sign(sign: ♻ node_crypto → sign, sign\\_data: Buffer)\n action `sync` sign_(sign: ♻ node_crypto → sign, private_key: String) returns(signature: Buffer)\n action `sync` create_verify(algorithm: String) returns(verify: ♻ node_crypto → verify)\n action `sync` update_verify(verify: ♻ node_crypto → verify, verify_data: Buffer)\n action `sync` verify_(verify: ♻ node_crypto → verify, object: String, signature: Buffer) returns(valid: Boolean)\n action `sync` create_DiffieHellman(prime_length: Number) returns(DiffieHellman: ♻ node_crypto → DiffieHellman)\n action `sync` generate_keys(DiffieHellman: ♻ node_crypto → DiffieHellman) returns(public_key: Buffer)\n action `sync` compute_secret(DiffieHellman: ♻ node_crypto → DiffieHellman, other_public_key: Buffer) returns(shared_secret: Buffer)\n action `sync` get_prime(DiffieHellman: ♻ node_crypto → DiffieHellman) returns(DH_prime: Buffer)\n action `sync` get_generator(DiffieHellman: ♻ node_crypto → DiffieHellman) returns(generator: Buffer)\n action `sync` get_public_key(DiffieHellman: ♻ node_crypto → DiffieHellman) returns(public_key: Buffer)\n action `sync` get_private_key(DiffieHellman: ♻ node_crypto → DiffieHellman) returns(private_key: Buffer)\n action `sync` set_public_key(DiffieHellman: ♻ node_crypto → DiffieHellman, public_key: Buffer)\n action `sync` set_private_key(DiffieHellman: ♻ node_crypto → DiffieHellman, private_key: Buffer)\n action `sync` get_DiffieHellman(group_name: String) returns(DiffieHellman: ♻ node_crypto → DiffieHellman)\n action `async` pbkdf2(password: String, salt: String, iterations: Number, keylen: Number) returns(derived_key: String)\n action `async` random_bytes(size: Number) returns(strong_data: Buffer)\n action `sync` DEFAULT\\_ENCODING() returns(default_encoding: String)\n action `sync` create_hmac(algorithm: String, key: String) returns(hmac: ♻ node_crypto → hmac)\n action `sync` create_DiffieHellmanWithPrime(prime: Buffer) returns(DiffieHellman: ♻ node_crypto → DiffieHellman)\n action `async` pseudo_random_bytes(size: Number) returns(non\\u002dstrong_data: Buffer)\n action `sync` update_hash_string(hash: ♻ node_crypto → hash, hash_data: String)\n action `async` new_guid() returns(guid: String)\n }\n}\n#lQzkFetSEgRfkoD1\nvar deviceid : String {\n}\n#BVGhpbmca\ntable Message {\n type = \"Object\";\n exported = true;\n persistent = false;\n fields {\n #wy6NESQzEaxcVB7P temp : Number\n }\n}\n#j113cC0ZjCAoNnDS meta import node_hash {\n pub \"ezbka\"\n usage {\n action `sync` sha256(value: String) returns(digest: String)\n action `sync` sha1(value: String) returns(digest: String)\n }\n #MBLWOTnilXzcOFAX resolve node_crypto = ♻ node_crypto with {\n }\n}\n#xm5N2eF8ZVFf8b5Z meta import application_insights {\n pub \"kgwpa\"\n usage {\n #BVGhpbmca\n table Options {\n type = \"Object\";\n exported = true;\n persistent = false;\n fields {\n #xYM2DFyGKHO12BbR track_uncaught_exceptions : Boolean\n }\n }\n #jQX44THKDWpQpHhU\n table Event_Options {\n type = \"Object\";\n exported = true;\n persistent = false;\n fields {\n #lTT22PAyjeXo47EF arguments : Json_Object\n #x7R256x3M3SbrPmi duration_in_ms : Number\n #gJxbxKuoVAifu2Lo duration_since : Number\n }\n }\n #ZGPN2rZbWO22hiYK\n table Request_Options {\n type = \"Object\";\n exported = true;\n persistent = false;\n fields {\n #x8GBdWsNotD1GLcL properties : Json_Object\n #b48kCc1eoez2GDNM duration_override : Number\n }\n }\n action `sync` init(options\\u003f: ♻ application_insights → Options) returns(active: Boolean)\n }\n}\n#OAqit425iZkuTA35\nvar hub : ♻ azure_event_hubs → Event_Hub {\n transient = true;\n}\n#x41EhzlB627EK4e1 meta import azure_event_hubs {\n pub \"qbjtg\"\n usage {\n #qy4yPchAE7AUedlB\n table Options {\n type = \"Object\";\n exported = true;\n persistent = false;\n fields {\n // Name of the event hub\n #BULIHveLGv3xhPGc hub_namespace : String\n // Shared Access Signature token; otherwise the server setting ``AZURE_SERVICEBUS_SAS_TOKEN`` is used.\n #xr7jIhKzmCpq0i5N sas_token : String\n }\n }\n #EyRHf2UILCkoocED\n table Event_Hub {\n type = \"Object\";\n exported = true;\n persistent = false;\n fields {\n #t4VjI1BVPLvcUl22 name : String\n }\n }\n action `sync` init(options\\u003f: ♻ azure_event_hubs → Options)\n action `async` send_message(hub: ♻ azure_event_hubs → Event_Hub, device_id: String, msg: String) returns(status: Number)\n action `async` create_event_hub_if_not_exists(name_: String) returns(hub: ♻ azure_event_hubs → Event_Hub)\n action `async` send_message_as_json(hub: ♻ azure_event_hubs → Event_Hub, device_id: String, msg: Json_Object) returns(status: Number)\n }\n}\n", "qetpa": "meta version \"v2.2,js,ctx,refs,localcloud,unicodemodel,allasync\";\nmeta name \"blank app\";\nmeta icon \"AddressBook\";\nmeta rootId \"xPVLZKRfDmGiasdkBt2RaNR4\";\nmeta allowExport \"yes\";\nmeta platform \"current\";\n#theme meta import theme {\n pub \"gnvi\"\n usage {\n action `async` title_1()\n action `async` title_2()\n action `async` title_3()\n action `async` subtle()\n action `async` normal()\n action `sync` example()\n action `async` accent()\n action `async` set_right_aligned(value: Boolean)\n action `async` huge()\n }\n}\n#main\naction main(\\u2756: * main_page_data) {\n if box→is_init then {\n skip;\n }\n if true then {\n skip;\n }\n meta page;\n meta sync;\n}\n#BbWFpbiBwYWdlIGRhdGEa\ntable main_page_data {\n type = \"Object\";\n persistent = false;\n}\n#YZGaVg1jhqq9sfncCGsIoHbh meta import forms {\n pub \"owroa\"\n usage {\n action `sync` `type` display_code()\n action `sync` `type` validator(s: String) returns(error: String)\n action `sync` button(text: String, on_tapped: Action)\n action `sync` checkbox(text: String, checked: Ref[Boolean])\n action `sync` input_string_collection(label: String, strings: String_Collection)\n action `sync` input_text_line(label: String, text: Ref[String])\n action `sync` input_text_area(label: String, text: Ref[String])\n action `sync` input_password(label: String, password: Ref[String])\n action `sync` input_number(label: String, text: Ref[String], changehandler: Number_Action)\n action `sync` labeled_content(label: String, content: ♻ forms → display_code)\n action `sync` indented_content(content: ♻ forms → display_code)\n action `sync` input_choice(label: String, choices: String_Collection, index: Ref[Number])\n action `sync` input_text_line_w\\u002f_validator(label: String, text: Ref[String], errorcheck: ♻ forms → validator, changehandler: Text_Action)\n }\n}\n#LHF2iIBnkOQcwhcoQKFiR4A2 meta import widgets {\n pub \"abgjb\"\n usage {\n action `sync` message(user: User, dt: DateTime, text: String)\n action `sync` picture(url: String)\n }\n}\n#iDxzKDq4042OKy7IX4V4D91F meta import layout {\n pub \"cwgn\"\n usage {\n action `sync` stretch_and_center()\n action `async` grid_of_squares(cell_content: Number_Action, count: Number, grid_width: Number, grid_height: Number)\n action `async` horizontal_hub_of_squares(cell_content: Number_Action, count: Number, cell_size: Number, group_width: Number, total_height: Number)\n action `async` vertical_hub_of_squares(cell_content: Number_Action, count: Number, cell_size: Number, total_width: Number, group_height: Number)\n }\n}\n", +"qkezc": "meta version \"v2.2,js,ctx,refs,localcloud,unicodemodel,allasync,upperplex\";\nmeta name \"getting started\";\nmeta icon \"CoffeeCup\";\nmeta color \"#ff007fff\";\nmeta rootId \"jgxw4hrQ2FJpvMX5ioKe2B98\";\nmeta hasIds \"yes\";\nmeta platform \"current\";\nmeta parentIds \"\";\n// A few tips on getting started with TouchDevelop. #docs #gettingStarted\n#xIo02XpbLanjKZPs4Os6Y4LA\naction main() {\n #Oqq61gE3scTEvYZY // {parentTopic:contents}\n #zLfUy9LLj4LtaQx1 // {priority:15}\n #BtM6DR2J5yHB6sPI // TouchDevelop lets you **create apps** on all your devices. Let's get started!\n #xTc92pAlcVjk7NIM // ## interactive tutorials\n #UR4kehofIixy8ZqD // Interactive tutorials let you learn at your own pace. We recommend starting out with one or more of these:\n #BMpEHAl89GLjB6Tj // * {follow:first steps with turtle}\n #RyRvlr3i8Xt2QwpU // * {follow:jumping bird tutorial}\n #ZQgFR1AVUm6THyGs // * {follow:coding jetpack jumper}\n #zObCeEa9dPLp8ooa // * {follow:pixel art tutorial}\n #zxrf3iOVA2LWSucN // Try also\n #q9JFJmh12AXcgatn // * [build your first app](http://aka.ms/buildyourfirstapp)\n #Fi2zIopLiFb4rNH4 // * Run an [Hour Of Code](https://www.touchdevelop.com/hoc) with TouchDevelop!\n #yx3F7H4uaTmcHwkO // Browse many other [interactive tutorials](/tutorials) and [courses](/courses). Learn how to build your own games, social apps, and more! Also, check out the book [TouchDevelop - Programming on the Go](/book). It's available as a free download!\n #xJmv15REfU94PGim // ## if you have programming experience...\n #fl1IdthF70YHQxDf // ### Traditional Languages\n #ss44jvTWrjOMlUod // {pic:eclipse:12x5}\n #h4UEzbiXxngho4qF // If you have experience with a traditional programming language such as Java, JavaScript, Python, C#, or C++:\n #P2cb12dV12LdnGN4 // * Start with [hello world](/helloworld) and create a TouchDevelop version of the classic 'hello world' app.\n #Tk1HQSMDs4fk4SuF // * Go to the [dev boot camp](/devbootcamp) and get a quick overview of the TouchDevelop language and environment.\n #xqE7TP69LpivSkjp // * Try a [social app tutorial](/socialapptutorials).\n #xM8eoCxsFuNcZ6Lc // ### Block Programming Environments\n #A6h4niF5i1xLuOXm // {pic:scratch:11x4}\n #k1oezDF4jvXHgk3V // If you have experience with block programming environments such as **Scratch**, **AppInventor**, **Snap!** (BYOB), **code.org**, **Blockly**, or other tools, let us show you how to [transition from blocks to text](/fromblockstotext).\n #KY8dTaEdqs4sjpRG // ## inform and instruct\n #Retn7qEvVW1pvEQZ // In addition to creating fun and useful apps, you can use TouchDevelop to create custom interactive tutorials to show users how to perform specific tasks. You can also create your own documentation topics to expand the TouchDevelop documentation!\n #xCY1IPuWs8bC15Fj // * [creating interactive tutorials](/creatinginteractivetutorials)\n #HIy9PSdtPgJXRY8Z // * [add your own docs](/addyourowndocs)\n}\n#kZWqFwNpvbKrHfETZ2TSQKCA\nvar scratch : Picture {\n is\\_resource = true;\n url = \"https://az31353.vo.msecnd.net/pub/fpxfkwlk\";\n transient = true;\n}\n#b97YU9g2RQFdWzG22RPqgK2Y\nvar eclipse : Picture {\n is\\_resource = true;\n url = \"https://az31353.vo.msecnd.net/pub/srtrixfh\";\n transient = true;\n}\n#SxNnQzF2puTSD7MMUORJP2UN\nvar turtle : Picture {\n is\\_resource = true;\n url = \"https://az31353.vo.msecnd.net/pub/pskgnelo\";\n transient = true;\n}\n", "spbd": "meta version \"v2.2,js,ctx,refs,localcloud,unicodemodel,allasync\";\nmeta name \"blank template\";\nmeta rootId \"s18cNgqmk4qdPwKNK0ppoMp2\";\nmeta allowExport \"yes\";\nmeta platform \"current\";\n#main\naction main() {\n skip;\n}\n", "szrna": "meta version \"v2.2,js,ctx,refs,localcloud,unicodemodel,allasync,upperplex\";\nmeta name \"export to app\";\nmeta rootId \"xp8sE0p9XtQHYy4T5VhcCufH\";\nmeta hasIds \"yes\";\nmeta platform \"current\";\nmeta parentIds \"\";\n// Export your scripts to Windows, Windows Phone or Web apps. #docs #exportToApp\n#main\naction main() {\n #mEtE4fv17EKWFNsk // {parentTopic:contents}\n #OyrhWsuD1E8yISz4 // You can export your scripts as **Windows** apps, **Windows Phone** apps, **Android** apps, **iPhone/iPad** apps that can be published in the app stores of each platform like the Apple App Store or the Windows Store. You can also export to **Azure** web sites or Office Mix.\n #WE7EBnFwXAl99qEN // ### export to App Studio (Windows, Windows Phone)\n #IttiVt6Tov08b0xK // Windows App Studio allows to export (some of) your script to **Windows** and **Windows Phone** through **a web interface**. However, some features such as network requests are not supported.\n #cwjQRgAGBrDnyXde // * **pros** no tools installation, straightforward web site to publish script to Windows, Windows Phone\n #cGhti0U1la6bYar3 // * **cons** some features such as network requests not supported. Only Windows and Windows Phone supported.\n #jcS5DkQwzxLcTDwC // Interrested? [Get started with App Studio](/exporttoappstudio).\n #xfQwOjyqbCZ6UelA // ### export to Cordova app (iOS, Android, Windows)\n #L1JWCQsWnRYB2dGP // Apache Cordova allows to build **Android**, **iOS**, **Windows**, **Windows Phone**, and more platforms. It also provides access to the hundreds of Cordova plugins to create rich apps in TouchDevelop.\n #xgbXNg3ylPwfJLBw // * **pros** target all platforms supported by Apache Cordova, including **iOS** and **Android**.\n #LMFUy87nZuwZ2okp // * **cons** requires running TouchDevelop locally and installing the Apache Cordova tools.\n #lhynaeP1iq2JdgWj // Interrested? [Get started with Cordova](/exporttocordova).\n #TFt2d3cjCzCX0jtD // ### export to Azure Web Apps (Node.JS)\n #TayahDhQnjYSgEyw // If you're not looking to create a client app, you can also convert a script into a [node.js](http://nodejs.org/) app running as Azure Web App. TouchDevelop also allows to use any [npm](https://www.npmjs.com/) packages after wrapping them into a script.\n #emixj6WcdUjIxT29 // Interrested? [Get started with Azure Web Apps](/exporttoazure).\n #u4X7JAa3t1Px3OWG // ### export to Raspberry PI (Node.JS)\n #LOwcrH5NUAqxKSqQ // You can export scripts to Node.JS and run them wherever Node.JS runs... including the Raspberry Pi 1 or 2!\n #xgUx84IiBWz5UzNv // Interrested? [Get started with Raspberry Pi apps](/raspberrypisetup)\n #loQbqxe3beLcUWdX // ### export to web app or Office Mix\n #WHdYF2YQa2Rm4ErK // * [Export to Office Mix](/officemixdocs) allows to create interactive apps that integrate in online Office Mix presentations.\n #fdHsLajmawNqeu7l // * **HTML5 WebApp** No need for walktrough, just hit the `WebApp` button and you are done!\n #Q23Xhi1Fw36lK2aX // ### where do I start?\n #cDLR6mK0SMJkC4dq // * open your script in the editor\n #IGlhqkpixFMY8PVk // * tap on the **script name** (in the example below, my script)\n #dmmiVzVZsmczyWfs // * go to the `[export]` section\n #w6iey58yu47LbDZd // * select the export option\n}\n#storelogos\nvar storelogos : Picture {\n is\\_resource = true;\n url = \"https://az31353.vo.msecnd.net/pub/fmiidrfd\";\n transient = true;\n}\n#pic\nvar pic : Picture {\n is\\_resource = true;\n transient = true;\n}\n", "szzdc": "meta version \"v2.2,js,ctx,refs,localcloud,unicodemodel,allasync,upperplex\";\nmeta name \"blank arduino\";\nmeta icon \"ArrowStandardCircle\";\nmeta color \"#ff00cc99\";\nmeta rootId \"xkbt9ErH776FGA72sWuqxeOz\";\nmeta iconArtId \"kzajxznr\";\nmeta allowExport \"yes\";\nmeta hasIds \"yes\";\nmeta platform \"current\";\nmeta parentIds \"\";\n// An Arduino sketch. #arduino #arduinoSketch\n#KUJMn0ag6zrqQys9\naction setup() {\n #qWODTg5ZnR95PTeF @\\u267b→arduino→pin_mode(13, @\\u267b→arduino→OUTPUT);\n meta private;\n}\n#UzRPACG9RBTCLU2MkuwLAhpD\naction loop() {\n #x5bamvNg9UVXaFY7 @\\u267b→arduino→digital_write(13, @\\u267b→arduino→HIGH);\n #UybvnpQJqqrqtrnH @\\u267b→arduino→delay(200);\n #xqXPRRCVUKc8rCTO @\\u267b→arduino→digital_write(13, @\\u267b→arduino→LOW);\n #um2lxP36WxO2OgOk @\\u267b→arduino→delay(200);\n meta private;\n}\n#iHY2wlj4qcvFdTHc meta import arduino {\n pub \"cqfda\"\n usage {\n action `sync` digital_read(pin: Number) returns(bit: Number)\n action `sync` digital_write(pin: Number, value: Number)\n action `sync` analog_read(pin: Number) returns(bit: Number)\n action `sync` analog_write(pin: Number, value: Number)\n action `async` pin_mode(pin: Number, mode: Number)\n action `sync` HIGH() returns(v: Number)\n action `sync` LOW() returns(v: Number)\n action `sync` OUTPUT() returns(v: Number)\n action `sync` INPUT() returns(v: Number)\n action `async` delay(millis: Number)\n action `sync` sketch(source: String)\n action `sync` static_buffer(bytes: String) returns(buf: Buffer)\n action `sync` INPUT\\_PULLUP() returns(v: Number)\n action `sync` LED\\_BUILTIN() returns(r: Number)\n action `sync` mac(address: String)\n action `sync` analog_reference(type: Number)\n action `sync` DEFAULT() returns(r: Number)\n action `sync` EXTERNAL() returns(r: Number)\n action `sync` tone(pin: Number, frequency: Number, duration: Number)\n action `sync` no_tone(pin: Number)\n action `sync` millis() returns(millis: Number)\n action `sync` micros() returns(micros: Number)\n action `sync` pulse_in(pin: Number, value: Number, timeout: Number) returns(micros: Number)\n action `sync` board(name: String)\n action `sync` print_value(name: String, value: Number)\n action `sync` print(text: String)\n action `sync` println(text: String)\n action `sync` map(value: Number, from_low: Number, from_high: Number, to_low: Number, to_high: Number) returns(r: Number)\n action `sync` constrain(value: Number, a: Number, b: Number) returns(r: Number)\n action `async` delay_microseconds(micros: Number)\n }\n}\n#xJTsvVkdQIFOcF0fRDHFLPLk\naction variables() {\n #xaFPmIVW8ylv5b9P // Initializes your global variables here.\n meta private;\n}\n#CvN1nxjx0F41jAPT meta import serial {\n pub \"kzkua\"\n usage {\n action `sync` read() returns(byte: Number)\n action `sync` available() returns(bytes: Number)\n action `sync` peek() returns(byte: Number)\n action `sync` print(msg: String)\n action `sync` println(msg: String)\n action `sync` write(byte: Number)\n }\n #ojn444WfORgPYrSW resolve arduino = ♻ arduino with {\n }\n}\n", @@ -211,13 +211,13 @@ {"name":"for","id":"xlkga","rootid":"xmpf","userid":"jeiv","description":"Repeat code a number of times. #docs #for #language","iconbackground":"#E25822","icon":"Revert","iconArtId":null,"splashArtId":null,"time":1412665885,"priority":10000,"parentTopic":"language"}, {"name":"for each","id":"ruis","rootid":"zxfb","userid":"jeiv","description":"Run code for each element in a collection. #docs #forEach #language","iconbackground":"#85BB65","icon":"AlignLeft","iconArtId":null,"splashArtId":null,"time":1412665927,"priority":10000,"parentTopic":"language"}, {"name":"forehead word guesser","id":"lubu","rootid":"auqsa","userid":"jeiv","description":"","iconbackground":"#9955BB","icon":"Controller","iconArtId":null,"splashArtId":null,"time":1402089234,"priority":10000,"platforms":["accelerometer"]}, -{"name":"from blocks to text","id":"pxipa","rootid":"gvwxajqc","userid":"jeiv","description":"A migration guide from block editors such as Scratch. #docs #blocks #Scratch #Snap #AppInvetor #Snap #blockly #BYOB","iconbackground":"#00008B","icon":"Location","iconArtId":null,"splashArtId":null,"time":1418865277,"priority":10000,"parentTopic":"gettingstarted"}, +{"name":"from blocks to text","id":"ayboi","rootid":"gvwxajqc","userid":"jeiv","description":"A migration guide from block editors such as Scratch. #docs #blocks #Scratch #Snap #AppInvetor #Snap #blockly #BYOB","iconbackground":"#00008B","icon":"Location","iconArtId":"azkhirjm","splashArtId":null,"time":1431093011,"priority":10000,"parentTopic":"gettingstarted"}, {"name":"fun with sphero","id":"txkya","rootid":"gshiehls","userid":"jeiv","description":"Control your Sphero like turtle! #docs #turtle #tutorials #Sphero","iconbackground":"#A1CAF1","icon":"ArrowCircleRounded","iconArtId":null,"splashArtId":null,"time":1415076614,"priority":10000,"platforms":["musicandsounds","bluetooth"],"screenshot":"https://az31353.vo.msecnd.net/pub/gftqcplh","parentTopic":"hardwaretutorials"}, {"name":"game board","id":"djse","rootid":"uels","userid":"jeiv","description":"A built-in 2D game engine. #docs #gameBoard #games","iconbackground":"#9955BB","icon":"Controller","iconArtId":null,"splashArtId":null,"time":1412686995,"priority":10000,"platforms":["accelerometer"],"parentTopic":"games"}, {"name":"game tutorials","id":"nqxba","rootid":"nssd","userid":"jeiv","description":"A list of interactive game tutorials #docs","iconbackground":"#008080","icon":"MultiplyCircle","iconArtId":null,"splashArtId":null,"time":1415145463,"priority":10000,"parentTopic":"tutorials"}, {"name":"gameloop","id":"jgpl","rootid":"ryega","userid":"jeiv","description":"An event that triggers many times a second. #docs #events","iconbackground":"#FF7518","icon":"Bolt","iconArtId":null,"splashArtId":null,"time":1412947137,"priority":10000,"parentTopic":"games"}, {"name":"games","id":"yuipc","rootid":"mbqg","userid":"jeiv","description":"Resources on creating games. #docs #games","iconbackground":"#008080","icon":"Notebook","iconArtId":null,"splashArtId":null,"time":1412687862,"priority":10000,"parentTopic":"contents"}, -{"name":"getting started","id":"cljk","rootid":"idsna","userid":"jeiv","description":"A few tips on getting started with TouchDevelop. #docs #gettingStarted","iconbackground":"#007FFF","icon":"CoffeeCup","iconArtId":null,"splashArtId":null,"time":1415145612,"priority":15,"parentTopic":"contents"}, +{"name":"getting started","id":"qkezc","rootid":"idsna","userid":"jeiv","description":"A few tips on getting started with TouchDevelop. #docs #gettingStarted","iconbackground":"#007FFF","icon":"CoffeeCup","iconArtId":null,"splashArtId":null,"time":1430950598,"priority":15,"parentTopic":"contents"}, {"name":"getting started with arduino","id":"ihfmg","rootid":"utpcc","userid":"jeiv","description":"A guide to developing Arduino with TouchDevelop. #docs #arduino","iconbackground":"#00CC99","icon":"ArrowCircleRounded","iconArtId":null,"splashArtId":null,"time":1426370132,"priority":10000}, {"name":"great game","id":"xdrz","rootid":"xdrz","userid":"jeiv","description":"","iconbackground":"#9955BB","icon":"Controller","iconArtId":null,"splashArtId":null,"time":1405034770,"priority":10000,"platforms":["musicandsounds"]}, {"name":"group scripts","id":"agbfe","rootid":"knqeb","userid":"jeiv","description":"A project is a script that can be edited by multiple users. #docs","iconbackground":"#66FF00","icon":"Mute","iconArtId":null,"splashArtId":null,"time":1430273090,"priority":10000,"parentTopic":"groups"}, @@ -225,7 +225,7 @@ {"name":"hardware tutorials","id":"pjybb","rootid":"hvuu","userid":"jeiv","description":"Interactive tutorials to program hardware gadgets with TouchDevelop. #docs","iconbackground":"#FF00FF","icon":"Notebook","iconArtId":null,"splashArtId":null,"time":1417788324,"priority":10000,"parentTopic":"tutorials"}, {"name":"hello world","id":"yznkb","rootid":"lzqxkvzl","userid":"jeiv","description":"A short tutorial for Java developers #docs #tutorials","iconbackground":"#007FFF","icon":"Wand","iconArtId":null,"splashArtId":null,"time":1412688174,"priority":10000,"parentTopic":"gettingstarted"}, {"name":"hidden scripts","id":"hcqlb","rootid":"oohc","userid":"jeiv","description":"Hiding and unhidding scripts. #docs","iconbackground":"#FF7518","icon":"Cactus","iconArtId":null,"splashArtId":null,"time":1413225132,"priority":10000,"parentTopic":"socialcoding"}, -{"name":"hide and seek scratch tutorial","id":"tssxc","rootid":"vdqqa","userid":"jeiv","description":"","iconbackground":"#FFA500","icon":"Tanktop","iconArtId":null,"splashArtId":null,"time":1414630862,"priority":10000,"platforms":["musicandsounds"]}, +{"name":"hide and seek scratch tutorial","id":"gjzbe","rootid":"vdqqa","userid":"jeiv","description":"A simple #scratch game.","iconbackground":"#FFA500","icon":"Tanktop","iconArtId":null,"splashArtId":null,"time":1431092441,"priority":10000,"platforms":["musicandsounds"]}, {"name":"history","id":"wpzv","rootid":"wpzv","userid":"jeiv","description":"Understand how the scripts are saved. #docs","iconbackground":"#E3256B","icon":"Revert","iconArtId":null,"splashArtId":null,"time":1413226626,"priority":10000,"parentTopic":"socialcoding"}, {"name":"hosted apps","id":"wmkqe","rootid":"cbdee","userid":"jeiv","description":"A description of hosted app #docs","iconbackground":"#FFFFFF","icon":"Video","iconArtId":"zubldkpr","splashArtId":null,"time":1429716162,"priority":10000,"parentTopic":"advancedtopics"}, {"name":"hour of code educator notes","id":"lugh","rootid":"gjvv","userid":"jeiv","description":"The recipe to run an awesome Hour Of Code™ with TouchDevelop! #docs #hourofcode","iconbackground":"#9955BB","icon":"Wand","iconArtId":null,"splashArtId":null,"time":1417736256,"priority":10000,"parentTopic":"teach"}, @@ -303,11 +303,11 @@ {"name":"recursion","id":"zqdka","rootid":"zqdka","userid":"jeiv","description":"Explain the principle of recursive action calls. #docs","iconbackground":"#EEDC82","icon":"Cycle","iconArtId":null,"splashArtId":null,"time":1374787923,"priority":10000}, {"name":"refactorings","id":"diwwa","rootid":"magu","userid":"jeiv","description":"Use TouchDevelop code editor to its fullest with #refactorings #docs","iconbackground":"#008080","icon":"Male","iconArtId":null,"splashArtId":null,"time":1412666493,"priority":10000,"parentTopic":"advancedtopics"}, {"name":"rss feeds","id":"wlbra","rootid":"jzzy","userid":"jeiv","description":"RSS feeds to track new scripts, etc... #docs","iconbackground":"#E25822","icon":"Paint","iconArtId":null,"splashArtId":null,"time":1422900797,"priority":10000,"parentTopic":"socialcoding"}, -{"name":"scratch cat tutorial","id":"svbva","rootid":"gowz","userid":"jeiv","description":"#docs #scratch #stepByStep #tutorials","iconbackground":"#FFA500","icon":"Flag","iconArtId":null,"splashArtId":null,"time":1414630829,"priority":10000,"platforms":["musicandsounds"],"screenshot":"https://az31353.vo.msecnd.net/pub/azkhirjm"}, -{"name":"scratch pong tutorial","id":"aakqc","rootid":"aldve","userid":"jeiv","description":"A tutorial to build a pong game using the Scratch library. #docs #tutorials #scratch","iconbackground":"#85BB65","icon":"NumberedList","iconArtId":null,"splashArtId":null,"time":1414630887,"priority":10000,"platforms":["musicandsounds"]}, -{"name":"scratch random number guesser notes","id":"njjjb","rootid":"gvwxajqc","userid":"jeiv","description":"A migration guide from block editors such as Scratch. #docs #blocks #Scratch #Snap #AppInvetor #Snap #blockly #BYOB #tutorials","iconbackground":"#FFA500","icon":"Bomb","iconArtId":null,"splashArtId":null,"time":1386312326,"priority":10000,"platforms":["musicandsounds"]}, +{"name":"scratch cat tutorial","id":"emszc","rootid":"gowz","userid":"jeiv","description":"#docs #scratch #stepByStep #tutorials","iconbackground":"#FFA500","icon":"Flag","iconArtId":null,"splashArtId":null,"time":1431092481,"priority":10000,"platforms":["musicandsounds"],"screenshot":"https://az31353.vo.msecnd.net/pub/azkhirjm"}, +{"name":"scratch pong tutorial","id":"ohzze","rootid":"aldve","userid":"jeiv","description":"A tutorial to build a pong game using the Scratch library. #docs #tutorials #scratch","iconbackground":"#85BB65","icon":"NumberedList","iconArtId":null,"splashArtId":null,"time":1431092461,"priority":10000,"platforms":["musicandsounds"]}, +{"name":"scratch random number guesser notes","id":"aevfg","rootid":"gvwxajqc","userid":"jeiv","description":"A migration guide from block editors such as Scratch. #docs #blocks #Scratch #Snap #AppInvetor #Snap #blockly #BYOB #tutorials","iconbackground":"#FFA500","icon":"Bomb","iconArtId":null,"splashArtId":null,"time":1431092319,"priority":10000,"platforms":["musicandsounds"]}, {"name":"scratch random number guesser tutorial","id":"rmoga","rootid":"gvwxajqc","userid":"jeiv","description":"A migration guide from block editors such as Scratch. #docs #blocks #Scratch #Snap #AppInvetor #Snap #blockly #BYOB #tutorials #stepbystep","iconbackground":"#00CC99","icon":"AlmostEqual","iconArtId":null,"splashArtId":null,"time":1387326471,"priority":10000,"platforms":["musicandsounds"],"screenshot":"https://az31353.vo.msecnd.net/pub/kromirev"}, -{"name":"scratch reference","id":"zwvsb","rootid":"ozsd","userid":"jeiv","description":"A complete reference manual of the Scratch library in TouchDevelop. #docs #scratch","iconbackground":"#007FFF","icon":"Ladder","iconArtId":null,"splashArtId":null,"time":1421454831,"priority":10000,"platforms":["accelerometer","musicandsounds"],"parentTopic":"fromblockstotext"}, +{"name":"scratch reference","id":"goqxa","rootid":"ozsd","userid":"jeiv","description":"A complete reference manual of the Scratch library in TouchDevelop. #docs #scratch","iconbackground":"#007FFF","icon":"Ladder","iconArtId":null,"splashArtId":null,"time":1431091982,"priority":10000,"platforms":["accelerometer","musicandsounds"],"parentTopic":"fromblockstotext"}, {"name":"script categories","id":"stscb","rootid":"stscb","userid":"jeiv","description":"A description of the script categories. #docs","iconbackground":"#008080","icon":"Beer","iconArtId":null,"splashArtId":null,"time":1413226221,"priority":10000,"parentTopic":"socialcoding"}, {"name":"script forks","id":"yict","rootid":"irkbb","userid":"jeiv","description":"Explains how forking scripts work. #docs","iconbackground":"#F5DEB3","icon":"Split","iconArtId":null,"splashArtId":null,"time":1412791954,"priority":10000,"parentTopic":"socialcoding"}, {"name":"script id","id":"kfsy","rootid":"htjz","userid":"jeiv","description":"What is the script id? #docs","iconbackground":"#FF7518","icon":"EmailDoc","iconArtId":null,"splashArtId":null,"time":1415067862,"priority":10000,"parentTopic":"socialcoding"}, @@ -325,7 +325,7 @@ {"name":"soundboard demo","id":"vxii","rootid":"matlavjh","userid":"jeiv","description":"Demo of the soundbaord tutorial.","iconbackground":"#FF00FF","icon":"SoundHigh","iconArtId":null,"splashArtId":null,"time":1383539953,"priority":10000,"platforms":["musicandsounds"]}, {"name":"soundboard tutorial","id":"uoozb","rootid":"matlavjh","userid":"jeiv","description":"Learn how to build a sound beat box using boxes. #docs #tutorials #pages #stepbystep","iconbackground":"#FF00FF","icon":"SoundHigh","iconArtId":null,"splashArtId":null,"time":1415076478,"priority":10000,"platforms":["musicandsounds"],"screenshot":"https://az31353.vo.msecnd.net/pub/edwmwvjo","parentTopic":"gametutorials"}, {"name":"speech","id":"lioqb","rootid":"tfrv","userid":"jeiv","description":"An overview of the speech related actions. #docs #speech","iconbackground":"#DAA520","icon":"Mic","iconArtId":null,"splashArtId":null,"time":1370997010,"priority":10000,"platforms":["speech"]}, -{"name":"spiral maker scratch tutorial","id":"jeue","rootid":"pctm","userid":"jeiv","description":"","iconbackground":"#FDEE00","icon":"Lightbulb","iconArtId":null,"splashArtId":null,"time":1387344026,"priority":10000}, +{"name":"spiral maker scratch tutorial","id":"uwdga","rootid":"pctm","userid":"jeiv","description":"","iconbackground":"#FDEE00","icon":"Lightbulb","iconArtId":null,"splashArtId":null,"time":1431092534,"priority":10000}, {"name":"sprite interaction tutorial","id":"fzqr","rootid":"tnfra","userid":"jeiv","description":"#docs #tutorial","iconbackground":"#FF2800","icon":"Fit","iconArtId":null,"splashArtId":null,"time":1413576254,"priority":10000}, {"name":"square poll tutorial","id":"jmyua","rootid":"wnljijkz","userid":"jeiv","description":"A tutorial to build an online poll. #docs #tutorials #stepByStep","iconbackground":"#FFA500","icon":"FourColumn","iconArtId":null,"splashArtId":null,"time":1403813705,"priority":10000,"platforms":["clouddata"],"screenshot":"https://az31353.vo.msecnd.net/pub/yzfcwcqe"}, {"name":"string casing","id":"bvyn","rootid":"ekrf","userid":"jeiv","description":"A piece of text. #docs #StringToLowerCase","iconbackground":"#800080","icon":"ABC","iconArtId":null,"splashArtId":null,"time":1368129984,"priority":10000}, @@ -382,7 +382,7 @@ {"title":"blank node library","id":"blanknodelibrary","icon":"ArrowStandardCircle","name":"node ADJ package","description":"An wrapper for a node package.","section":"web apps","scriptid":"ibksb","editorMode":3}, {"title":"blank arduino","id":"blankarduino","icon":"ArrowCircleRounded","name":"ADJ sketch","description":"An empty Arduino sketch.","section":"makers","scriptid":"szzdc","editorMode":2}, {"title":"blank esplora","id":"blankesplora","icon":"Controller","name":"ADJ esplora","description":"An empty Arduino Esplora script.","section":"makers","scriptid":"lsrh","editorMode":2}, -{"title":"blank engduino","id":"blankengduino","icon":"Controller","name":"ADJ engduino","description":"An empty Engduino script.","section":"makers","scriptid":"bhjyb","editorMode":2}, +{"title":"blank engduino","id":"blankengduino","icon":"Controller","name":"ADJ engduino","description":"An empty Engduino script.","section":"makers","scriptid":"goale","editorMode":2}, {"title":"blank docs","id":"blankdocs","icon":"Controller","name":"ADJ docs","description":"An empty documentation page.","section":"touchdevelop","scriptid":"krvn","editorMode":3}, {"title":"blank tutorial","id":"blanktutorial","icon":"Controller","name":"ADJ tutorial","description":"An empty interactive tutorial.","section":"touchdevelop","scriptid":"wonx","editorMode":3}, {"title":"blank script plugin","id":"blankscriptplugin","icon":"Brush","name":"ADJ plugin","description":"An empty script editor plugin.","section":"touchdevelop","scriptid":"tiwt","editorMode":3},