Sha256: 8c55fa4b9b7e03235b2682ad412b9c1c068ce68c18643e9bc0136b1937aaf2af
Contents?: true
Size: 923 Bytes
Versions: 2
Compression:
Stored size: 923 Bytes
Contents
<!DOCTYPE html> <html> <head> <meta charset="UTF-8" /> <title>Hello React!</title> <script src="https://fb.me/react-15.0.1.js"></script> <script src="https://fb.me/react-dom-15.0.1.js"></script> <script src="http://cdn.opalrb.org/opal/0.9.2/opal.js"></script> <script src="http://cdn.opalrb.org/opal/0.9.2/opal-parser.js"></script> <script src="../dist/opal-react.js"></script> <script type="text/javascript">Opal.load('opal-parser')</script> </head> <body> <div id="content"></div> <script type="text/ruby"> # tutorial1.rb class CommentBox < React::Component def render div(className: 'commentBox') do 'Hello, world! I am a CommentBox.' end end end include React::DOM ReactDOM.render( CommentBox(), $$.document.getElementById('content') ) </script> </body> </html>
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
opal-react-0.0.4 | tutorial/tutorial1.html |
opal-react-0.0.3 | tutorial/tutorial1.html |