This repository is a starter for basic client side JavaScript development.
It is configured for automated testing using GitHub actions and Jest.
The automated tests check for an alert()
, some JavaScript variables,
and some content injected into the HTML using document.write()
.
If you want to pass the tests, add the script with the alert()
just
inside the opening <head>
tag of the docs/index.html
file.
<script>
alert( "Check out our amazing prices!" );
</script>
In the above script, add statements to set up the pricing variables.
const proPrice = 99;
const enterprisePrice = 2 * proPrice;
In the HTML body, replace the Pro pricing of 15
with a call to
document.write()
.
<script>document.write( proPrice );</script>
Do the same for the Enterprise pricing.
<script>document.write( enterprisePrice );</script>
This post describes how to set up your local development environment.