Skip to content

Instantly share code, notes, and snippets.

@pugiemonn
Last active November 23, 2016 21:06
Show Gist options
  • Save pugiemonn/132ece74dc41562db99e1cb3a26dcacf to your computer and use it in GitHub Desktop.
Save pugiemonn/132ece74dc41562db99e1cb3a26dcacf to your computer and use it in GitHub Desktop.
<!DOCTYPE html>
<html lang="en">
<head>
<!-- Required meta tags always come first -->
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta http-equiv="x-ua-compatible" content="ie=edge">
</head>
<body>
<div id="root">
<!-- This div's content will be managed by React. -->
</div>
<script src="https://unpkg.com/react@15/dist/react.js"></script>
<script src="https://unpkg.com/react-dom@15/dist/react-dom.js"></script>
<script src="https://unpkg.com/babel-standalone@6.19.0/babel.min.js"></script>
<script type="text/babel">
var ClickableImage = function(props) { return (
<a href={props.href}> <img src={props.src} />
</a> );
};
ReactDOM.render(
<ClickableImage href="http://google.com" src="http://goo.gl/QlB7wl" />, document.getElementById("root")
);
</script>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment