Skip to content

Commit 9681173

Browse files
authored
Merge pull request #192 from kylebakerio/patch-3
Update example to include dynamic reference to new markdown from #188
2 parents 082a718 + ba8b140 commit 9681173

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

examples/index.html

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,7 @@
5858
clear: both;
5959
}
6060
</style>
61+
<script src="https://cdnjs.cloudflare.com/ajax/libs/showdown/1.9.1/showdown.min.js"></script>
6162
</head>
6263
<body>
6364
<h1>A-Frame Super Hands Component</h1>
@@ -119,6 +120,17 @@ <h1>A-Frame Super Hands Component</h1>
119120
colliderEndEventProperty: clearedEls"</pre>
120121
<p>This scene also shows the fallback movement that occurs when physics
121122
is not available.</p>
123+
<h2>Quick guide to adding making something grabbable with physics on your site</h2>
124+
<div id="dynamic-guide-here"></div>
125+
<script>
126+
(async function() {
127+
var converter = new showdown.Converter();
128+
var response = await fetch('https://raw.githubusercontent.com/wmurphyrd/aframe-super-hands-component/master/getting-started.md');
129+
var md = await response.text()
130+
var html = converter.makeHtml(md);
131+
document.querySelector('#dynamic-guide-here').innerHTML = html;
132+
})()
133+
</script>
122134
<!--
123135
<a id="sticky" class="example" href="sticky/">Sticky Grab via
124136
Custom Button Mapping<br />
@@ -141,4 +153,5 @@ <h1>A-Frame Super Hands Component</h1>
141153
<style>.github-corner:hover .octo-arm{animation:octocat-wave 560ms ease-in-out}@keyframes octocat-wave{0%,100%{transform:rotate(0)}20%,60%{transform:rotate(-25deg)}40%,80%{transform:rotate(10deg)}}@media (max-width:500px){.github-corner:hover .octo-arm{animation:none}.github-corner .octo-arm{animation:octocat-wave 560ms ease-in-out}}
142154
</style>
143155
</body>
156+
144157
</html>

0 commit comments

Comments
 (0)