Skip to content

Commit

Permalink
exploring props - part 1
Browse files Browse the repository at this point in the history
  • Loading branch information
StephenGrider committed Mar 15, 2015
1 parent df8b9ed commit d67b329
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions badge/index.html
@@ -0,0 +1,24 @@
<head>
<script src="http://fb.me/react-0.13.0.js"></script>
<script src="http://fb.me/JSXTransformer-0.13.0.js"></script>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.2/css/bootstrap.min.css">
</head>
<body>
</body>

<script type="text/jsx">
// Define a `class`
var Badge = React.createClass({
render: function() {
return <button class="btn btn-primary" type="button">
Messages <span class="badge">4</span>
</button>
}
});

// React, please render this class
var element = React.createElement(Badge);

// React, after you render this class, please place it in my body tag
React.render(element, document.body);
</script>

0 comments on commit d67b329

Please sign in to comment.