Need to Code?
Simple HTML and JavaScript
Many AR packages require JavaScript.
JavaScript is one of the simpler scripting languages. It is very popular in website design.
This "Build Your Next AR/VR Web App Using JavaScript" medium article by Kisten Carter is a good introduction.
A simple HTML (web) page
<!DOCTYPE html>
<html>
<body>
<h1>The script element</h1>>
<p id="demo"></p>
<script>
document.getElementById("demo").innerHTML = "Hello Digital Literacy!";
</script>
</body>
</html>
Line 1 is a tag and commands are inside the < >
Line 2 is the start of the HTML (hypertext markup language)
Line 3 starts the BODY content-what you see on a web page goes in here
Line 4 creates a HEADING 1 tag. You have to close the tag as well so the computer knows when to stop the Heading format. You can have h1 (biggest) h2 and so on..
Line 5 creates a paragraph called demo
Line 6 tells the computer to be ready for a script inside the web page.
Line 7 tells the computer to get the web page paragraph section that says demo and display text there. You can test this yourself at https://www.w3schools.com/tags/tag_script.asp
Lines 8-10 are to tell the computer to stop the tags (tags are nested within each other).
You can save the above HTML as index.html in a text editor and try to open it yourself in a web browser (Chrome, Firefox)...
You can find JavaScript in HTML code of many webpages, shown by the script tag:
<script>
document.getElementById("demo").innerHTML = "Hello JavaScript!";
</script>
So I recommend learning HTML and CSS with the live (run as you code) editor codepen.
Once you have a grasp of the above, try learning AFrame in Codepen.
Reference
CARTER, K. 3 July 2019. Build Your Next AR/VR Web App Using JavaScript. Kristen Carter [Online]. Available: https://medium.com/@kristen.carter/build-your-next-ar-vr-web-app-using-javascript-32d3252e5756 [Accessed 20 May 2021].
Resources
Learn JavaScript with https://www.w3schools.com/js/ or https://www.codecademy.com/learn/introduction-to-javascript (many free tutorials) or https://www.datacamp.com/ (some free tutorials, all free to students and academics).
You can also see if there are Coder Dojo near you, there is one in Western Australia. https://fogartyfoundation.org.au/why-you-should-be-coding-with-coderdojo-wa/
Last updated
Was this helpful?