[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-7743":3},{"id":4,"name":5,"fullName":6,"owner":5,"repo":5,"description":7,"homepage":8,"htmlUrl":9,"language":10,"languages":9,"totalLinesOfCode":9,"stars":11,"forks":12,"watchers":13,"openIssues":14,"contributorsCount":15,"subscribersCount":15,"size":15,"stars1d":16,"stars7d":17,"stars30d":18,"stars90d":15,"forks30d":15,"starsTrendScore":19,"compositeScore":20,"rankGlobal":9,"rankLanguage":9,"license":21,"archived":22,"fork":22,"defaultBranch":23,"hasWiki":22,"hasPages":24,"topics":25,"createdAt":9,"pushedAt":9,"updatedAt":32,"readmeContent":33,"aiSummary":34,"trendingCount":15,"starSnapshotCount":15,"syncStatus":35,"lastSyncTime":36,"discoverSource":37},7743,"opal","opal\u002Fopal","Ruby ♥︎ JavaScript","https:\u002F\u002Fopalrb.com",null,"Ruby",4924,336,92,80,0,1,5,11,3,29.58,"MIT License",false,"master",true,[26,27,28,29,30,5,31],"browser","compiler","javascript","js","nodejs","ruby","2026-06-12 02:01:43","\u003Ch1 align=\"center\">\n  \u003Cimg src=\"https:\u002F\u002Fsecure.gravatar.com\u002Favatar\u002F88298620949a6534d403da2e356c9339?s=420\"\n  align=\"center\" title=\"Opal logo by Elia Schito\" width=\"105\" height=\"105\" \u002F>\n  \u003Cbr\u002F>\n  Opal  \u003Cbr\u002F>\n  \u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FOpal-Ruby%20💛%20JavaScript-yellow.svg?logo=ruby&style=social&logoColor=777\" alt=\"Opal-Ruby 💛 JavaScript\"\u002F>\n\u003C\u002Fh1>\n\n\u003Cp align=\"center\">\n  \u003Cem>\u003Cstrong>Opal\u003C\u002Fstrong> is a Ruby to JavaScript source-to-source compiler.\u003Cbr>\n    It also has an implementation of the Ruby \u003Ccode>corelib\u003C\u002Fcode> and \u003Ccode>stdlib\u003C\u002Fcode>.\u003C\u002Fem>\n\u003C\u002Fp>\n\n\u003Cp align=\"center\">\n  \u003Cstrong>Community:\u003C\u002Fstrong>\u003Cbr>\n  \u003Ca href=\"https:\u002F\u002Fstackoverflow.com\u002Fquestions\u002Fask?tags=opalrb\">\u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Fstackoverflow-%23opalrb-orange.svg?style=flat\" alt=\"Stack Overflow\" title=\"\" \u002F>\u003C\u002Fa>\n  \u003Ca href=\"#backers\">\u003Cimg src=\"https:\u002F\u002Fopencollective.com\u002Fopal\u002Fbackers\u002Fbadge.svg\" alt=\"Backers on Open Collective\" title=\"\" \u002F>\u003C\u002Fa>\n  \u003Ca href=\"#sponsors\">\u003Cimg src=\"https:\u002F\u002Fopencollective.com\u002Fopal\u002Fsponsors\u002Fbadge.svg\" alt=\"Sponsors on Open Collective\" title=\"\" \u002F>\u003C\u002Fa>\n  \u003Ca href=\"https:\u002F\u002Fslack.opalrb.com\u002F\">\u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Fslack-join%20chat-46BC99?logo=slack&style=flat\" alt=\"Slack\" title=\"Join Chat\" \u002F>\u003C\u002Fa>\n  \u003Ca href=\"https:\u002F\u002Fopalrb.com\u002Fdocs\">\u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Fdocs-updated-blue.svg\" alt=\"Documentation\" title=\"\" \u002F>\u003C\u002Fa>\n\n  \u003Cbr>\n  \u003Cstrong>Code:\u003C\u002Fstrong>\u003Cbr>\n  \u003Ca href=\"https:\u002F\u002Fbadge.fury.io\u002Frb\u002Fopal\">\u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fgem\u002Fv\u002Fopal.svg?style=flat\" alt=\"Gem Version\" title=\"\" \u002F>\u003C\u002Fa>\n  \u003Ca href=\"https:\u002F\u002Fgithub.com\u002Fopal\u002Fopal\u002Factions?query=workflow%3Abuild\">\u003Cimg src=\"https:\u002F\u002Fgithub.com\u002Fopal\u002Fopal\u002Fworkflows\u002Fbuild\u002Fbadge.svg\" alt=\"Build Status\" \u002F>\u003C\u002Fa>\n  \u003Ca href=\"https:\u002F\u002Fcodeclimate.com\u002Fgithub\u002Fopal\u002Fopal\">\u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fcodeclimate\u002Fmaintainability-percentage\u002Fopal\u002Fopal.svg\" alt=\"Code Climate\" title=\"\" \u002F>\u003C\u002Fa>\n  \u003Ca href=\"https:\u002F\u002Fcoveralls.io\u002Fgithub\u002Fopal\u002Fopal?branch=master\">\u003Cimg src=\"https:\u002F\u002Fcoveralls.io\u002Frepos\u002Fopal\u002Fopal\u002Fbadge.svg?branch=master&amp;service=github\" alt=\"Coverage Status\" title=\"\" \u002F>\u003C\u002Fa>\n\n  \u003Cbr>\n  \u003Cstrong>Sponsors:\u003C\u002Fstrong>\n  \u003Cbr\u002F>\u003Ca href=\"https:\u002F\u002Fnebulab.it?utm_source=github&utm_medium=badge\">\u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fstatic\u002Fv1?label=Nebulab&message=Open+Source+Fridays&color=%235dbefd&logo=data:image\u002Fpng;base64,iVBORw0KGgoAAAANSUhEUgAAABwAAAAcCAYAAAByDd+UAAAACXBIWXMAABYlAAAWJQFJUiTwAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAMQSURBVHgBrZZNTxNRFIbfczsgIMQiLBCRFDaGhUr9A9iiIa5EEneIwE\u002FAlRsNv8KlIKwFl35RTUBX8rFBdiVKAgqmXSCY0M71nJl+zJTOdKh9k6Yzc8\u002FcZ86555x7CQE0mji5hSyGlQoNaOgIPwrnhtIArWszu4EQFudjdR8rzUV+gw8\u002FZMZB9IwvIwimJJGafhmjWZwFOJ7QkYzWCwTdj+qUDJGKz8Rou3RAlT4YS+hHWW2u\u002FQdM1MNzrI6+zwyXDrg8FANStIDaSXOIJ5whLgAljOIZiglRK6U4vDfz4S2ElGGJWsEaQkCTUbhtNbV+lb+xgFY2Bs9ET0h\u002FGzBxlfAkqnCUKY5xKfVLbsi1\u002FR126lcF6WgCYp2ES42EBp6tvQFY+alLTUlrUxizJEVNWiVwBkVagGg7oe+CDclLYOfrgMdfTBz8PfWa1lkzbsDEsH\u002F5FyF9YUK0zQ1xwpoZtsm9pwxMRLyA9wyi0A2Jcjl1NNqeeEFEimxYPkmWd014ikIDnDTeBb53DOweaRxnvWGyhnmYfPZWGt487sNi6lsK67\u002FlZ1oZGOtUaD3nhtU7etXXfe0VzrzCBgLKCR68rNDX6oaJlvd0xXnklbSfgSTL\u002FQghXF8EP980cVKyVL\u002FYs9UDVFJa8Tdt+1lYmcmJM3Vd4UEvWeslRf32h9ubrVRl77gBrCto85OfUU+LXTMGx+JuN2Hoin3\u002FZkfjj6ObBAknV+KG4jpc9BqXMEpiCMz6Z9ZQ12kvJZxb6co4Zr1W83esY8F2OYsIe+eEyfTiVXczCl7uM2wliHfMEJaRc3Wa++mLUotrF4EW7h6f94Dvh6aVFM60Fy8Xkya+BfBOjh5yUWhqY0vmKi9q1GnVxZ7sHKIWSs7FQ71yUagkRTTCfymnVY1gsgHHC5z8hbUjaz0Fr8ZanXhX0pPOw5SrV8wNGjNscMrTKpXKaj05f9twVYHnMZGPHEuwTwEBNi+3NGiNt6GRcsfEIAfhp2cAV3cQLtXoOz7q8+ZJRLx3kmxn4dy7aas1SrfiBpKraV\u002F9A+PSJLDAXLUvAAAAAElFTkSuQmCC\" alt=\"Nebulab: Open Source Fridays\" \u002F>\u003C\u002Fa>\n\u003C\u002Fp>\n\n## Usage\n\nSee the website for more detailed instructions and guides for Rails, jQuery, Sinatra, rack, CDN, etc. [https:\u002F\u002Fopalrb.com](https:\u002F\u002Fopalrb.com).\n\n### Compiling Ruby code with the CLI (Command Line Interface)\n\nContents of `app.rb`:\n\n```ruby\nputs 'Hello world!'\n```\n\nThen from the terminal\n\n```bash\n$ opal --compile app.rb > app.js # The Opal runtime is included by default\n                                 # but can be skipped with the --no-opal flag\n```\n\nThe resulting JavaScript file can be used normally from an HTML page:\n\n```html\n\u003Cscript src=\"app.js\">\u003C\u002Fscript>\n```\n\nBe sure to set the page encoding to `UTF-8` inside your `\u003Chead>` tag as follows:\n\n```html\n\u003C!DOCTYPE html>\n\u003Chtml>\n  \u003Chead>\n    \u003Cmeta charset=\"utf-8\">\n    \u003Cscript src=\"app.js\">\u003C\u002Fscript>\n    …\n  \u003C\u002Fhead>\n  \u003Cbody>\n    …\n  \u003C\u002Fbody>\n\u003C\u002Fhtml>\n```\n\nJust open this page in a browser and check the JavaScript console.\n\n\n### Compiling Ruby code from Ruby\n\n`Opal.compile` is a simple interface to just compile a string of Ruby into a\nstring of JavaScript code.\n\n```ruby\nOpal.compile(\"puts 'wow'\")  # => \"(function() { ... self.$puts(\"wow\"); ... })()\"\n```\n\nRunning this by itself is not enough; you need the opal runtime\u002Fcorelib.\n\n#### Using Opal::Builder\n\n`Opal::Builder` can be used to build the runtime\u002Fcorelib into a string.\n\n```ruby\nOpal::Builder.build('opal') #=> \"(function() { ... })()\"\n```\n\nor to build an entire app including dependencies declared with `require`:\n\n```ruby\nbuilder = Opal::Builder.new\nbuilder.build_str('require \"opal\"; puts \"wow\"', '(inline)')\nFile.binwrite 'app.js', builder.to_s # must use binary mode for writing\n```\n\n\n### Compiling Ruby code from HTML (or using it as you would with inline JavaScript)\n\n`opal-parser` allows you to *eval* Ruby code directly from your HTML (and from Opal) files without needing any other building process.\n\nSo you can create a file like the one below, and start writing ruby for\nyour web applications.\n\n\n```html\n\u003C!DOCTYPE html>\n\u003Chtml>\n  \u003Chead>\n    \u003Cmeta charset=\"utf-8\">\n    \u003Cscript src=\"https:\u002F\u002Fcdn.opalrb.com\u002Fopal\u002Fcurrent\u002Fopal.js\">\u003C\u002Fscript>\n    \u003Cscript src=\"https:\u002F\u002Fcdn.opalrb.com\u002Fopal\u002Fcurrent\u002Fopal-parser.js\" onload=\"Opal.load('opal-parser')\">\u003C\u002Fscript>\n\n    \u003Cscript type=\"text\u002Fruby\">\n      puts \"hi\"\n    \u003C\u002Fscript>\n\n  \u003C\u002Fhead>\n  \u003Cbody>\n  \u003C\u002Fbody>\n\u003C\u002Fhtml>\n```\n\nJust open this page and check the JavaScript console.\n\n**NOTE**: Although this is possible, this is not really recommended for\nproduction and should only be used as a quick way to get your hands\non opal.\n\n## Running tests\n\nSetup the project:\n\n    $ bin\u002Fsetup\n\nThe test suite can be run using:\n\n    $ bundle exec rake\n\nThis command will run all RSpec and MSpec examples in sequence.\n\n\n### MSpec\n\n[MSpec][] tests can be run with:\n\n    $ rake mspec\n\nAlternatively, you can just load up a rack instance using `rackup`, and\nvisit `http:\u002F\u002Flocalhost:9292\u002F` in any web browser.\n\n\n### RSpec\n\n[RSpec][] tests can be run with:\n\n    $ rake rspec\n\n\n### Automated runs\n\nA `Guardfile` with decent mappings between specs and lib\u002Fcorelib\u002Fstdlib files is in place.\nRun `bundle exec guard -i` to start `guard`.\n\n## Code Overview\n\nWhat code is supposed to run where?\n\n* `lib\u002F` code runs inside your Ruby env. It compiles Ruby to JavaScript.\n* `opal\u002F` is the runtime+corelib for our implementation (runs in browser).\n* `stdlib\u002F` is our implementation of Ruby's stdlib. It is optional (runs in browser).\n\n### lib\u002F\n\nThe `lib` directory holds the **Opal parser\u002Fcompiler** used to compile Ruby\ninto JavaScript. It is also built ready for the browser into `opal-parser.js`\nto allow compilation in any JavaScript environment.\n\n### opal\u002F\n\nThis directory holds the **Opal runtime and corelib** implemented in Ruby and\nJavaScript.\n\n### stdlib\u002F\n\nHolds the **stdlib currently supported by Opal**. This includes `Observable`,\n`StringScanner`, `Date`, etc.\n\n## Browser support\n\n* Internet Explorer 11\n* Firefox (Current - 1) or Current\n* Chrome (Current - 1) or Current\n* Safari (Current - 1) or Current\n* Opera (Current - 1) or Current\n\nAny problems encountered using the browsers listed above should be reported as bugs.\n\n(Current - 1) or Current denotes that we support the current stable version of\nthe browser and the version that preceded it. For example, if the current\nversion of a browser is 24.x, we support the 24.x and 23.x versions.\n\n12.1x or (Current - 1) or Current denotes that we support Opera 12.1x as well\nas the last 2 versions of Opera. For example, if the current Opera version is 20.x,\nthen we support Opera 12.1x, 19.x and 20.x but not Opera 15.x through 18.x.\n\n## Contributors\n\nThis project exists thanks to all the people who contribute. [![contributors](https:\u002F\u002Fopencollective.com\u002Fopal\u002Fcontributors.svg?width=890&button=false\")](https:\u002F\u002Fgithub.com\u002Fopal\u002Fopal\u002Fgraphs\u002Fcontributors)\n\n## Versioning\n\nOpal will broadly follow semver as a version policy, trying to bump the major version when introducing breaking changes.\nBeing a language implementation we're also aware that there's a fine line between what can be considered breaking and what is expected to be \"safe\" or just \"additive\". Moving forward we'll attempt to better clarify what interfaces are meant to be public and what should be considered private.\n\n## Backers\n\nThank you to all our backers! 🙏 [[Become a backer](https:\u002F\u002Fopencollective.com\u002Fopal#backer)]\n\n\u003Ca href=\"https:\u002F\u002Fopencollective.com\u002Fopal#backers\" target=\"_blank\">\u003Cimg src=\"https:\u002F\u002Fopencollective.com\u002Fopal\u002Fbackers.svg?width=890\" alt=\"Become a Backer Button\" \u002F>\u003C\u002Fa>\n\u003Ca href=\"https:\u002F\u002Fopencollective.com\u002Fopal\u002Fsponsor\u002F1\u002Fwebsite\" target=\"_blank\">\u003Cimg src=\"https:\u002F\u002Fopencollective.com\u002Fopal\u002Fsponsor\u002F1\u002Favatar.svg\">\u003C\u002Fa>\n\u003Ca href=\"https:\u002F\u002Fopencollective.com\u002Fopal\u002Fsponsor\u002F2\u002Fwebsite\" target=\"_blank\">\u003Cimg src=\"https:\u002F\u002Fopencollective.com\u002Fopal\u002Fsponsor\u002F2\u002Favatar.svg\">\u003C\u002Fa>\n\u003Ca href=\"https:\u002F\u002Fopencollective.com\u002Fopal\u002Fsponsor\u002F3\u002Fwebsite\" target=\"_blank\">\u003Cimg src=\"https:\u002F\u002Fopencollective.com\u002Fopal\u002Fsponsor\u002F3\u002Favatar.svg\">\u003C\u002Fa>\n\u003Ca href=\"https:\u002F\u002Fopencollective.com\u002Fopal\u002Fsponsor\u002F4\u002Fwebsite\" target=\"_blank\">\u003Cimg src=\"https:\u002F\u002Fopencollective.com\u002Fopal\u002Fsponsor\u002F4\u002Favatar.svg\">\u003C\u002Fa>\n\u003Ca href=\"https:\u002F\u002Fopencollective.com\u002Fopal\u002Fsponsor\u002F5\u002Fwebsite\" target=\"_blank\">\u003Cimg src=\"https:\u002F\u002Fopencollective.com\u002Fopal\u002Fsponsor\u002F5\u002Favatar.svg\">\u003C\u002Fa>\n\u003Ca href=\"https:\u002F\u002Fopencollective.com\u002Fopal\u002Fsponsor\u002F6\u002Fwebsite\" target=\"_blank\">\u003Cimg src=\"https:\u002F\u002Fopencollective.com\u002Fopal\u002Fsponsor\u002F6\u002Favatar.svg\">\u003C\u002Fa>\n\u003Ca href=\"https:\u002F\u002Fopencollective.com\u002Fopal\u002Fsponsor\u002F7\u002Fwebsite\" target=\"_blank\">\u003Cimg src=\"https:\u002F\u002Fopencollective.com\u002Fopal\u002Fsponsor\u002F7\u002Favatar.svg\">\u003C\u002Fa>\n\u003Ca href=\"https:\u002F\u002Fopencollective.com\u002Fopal\u002Fsponsor\u002F8\u002Fwebsite\" target=\"_blank\">\u003Cimg src=\"https:\u002F\u002Fopencollective.com\u002Fopal\u002Fsponsor\u002F8\u002Favatar.svg\">\u003C\u002Fa>\n\u003Ca href=\"https:\u002F\u002Fopencollective.com\u002Fopal\u002Fsponsor\u002F9\u002Fwebsite\" target=\"_blank\">\u003Cimg src=\"https:\u002F\u002Fopencollective.com\u002Fopal\u002Fsponsor\u002F9\u002Favatar.svg\">\u003C\u002Fa>\n\n\n## Sponsors\n\n### Donations\n\nSupport this project by becoming a sponsor. Your logo will show up here with a link to your website. [[Become a sponsor](https:\u002F\u002Fopencollective.com\u002Fopal#sponsor)]\n\n\u003Ca href=\"https:\u002F\u002Fopencollective.com\u002Fopal\u002Fsponsor\u002F0\u002Fwebsite\" target=\"_blank\">\u003Cimg src=\"https:\u002F\u002Fopencollective.com\u002Fopal\u002Fsponsor\u002F0\u002Favatar.svg\" alt=\"Become a Sponsor Button\">\u003C\u002Fa>\n\n### Sponsored Contributions\n\n\u003Ca href=\"https:\u002F\u002Fnebulab.it\u002F?utm_source=github&utm_medium=sponsors\" target=\"_blank\">\u003Cimg src=\".github\u002Fsponsors\u002Fnebulab-logo.svg\" alt=\"Nebulab Logo\">\u003C\u002Fa>\n\n\u003Ca href=\"https:\u002F\u002Fwww.testmu.ai\u002F?utm_source=github&utm_medium=sponsors\" target=\"_blank\">\u003Cimg src=\".github\u002Fsponsors\u002Ftestmu-ai-black.svg\" alt=\"TestMu AI Logo\" width=\"200\">\u003C\u002Fa>\n\n\n## License\n\n(The MIT License)\n\nCopyright (C) 2013-2021 by Adam Beynon and the Opal contributors\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and\u002For sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in\nall copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\nTHE SOFTWARE.\n\n\n[MSpec]: https:\u002F\u002Fgithub.com\u002Fruby\u002Fmspec#readme\n[RSpec]: https:\u002F\u002Fgithub.com\u002Frspec\u002Frspec#readme\n","Opal 是一个将 Ruby 代码编译成 JavaScript 的源到源编译器，同时它还实现了 Ruby 的核心库和标准库。该项目支持在浏览器或 Node.js 环境中运行 Ruby 代码，使得开发者可以利用 Ruby 的语法和生态系统来构建前端应用或服务器端脚本。Opal 通过提供与原生 Ruby 几乎相同的 API 来确保开发体验的一致性，并且能够无缝集成现有的 JavaScript 工具链。对于希望在客户端使用 Ruby 语言进行开发的团队或者想要复用 Ruby 代码库的项目来说，Opal 是一个理想的选择。",2,"2026-06-11 03:14:08","top_language"]