Template Literal
I started this analysis on my main site - I admit I did't really understand them at the time.
I saw Template Literals used on my page on Bubbling and Capturing with respect to DOM
The code from the Bubbling and Capturing example:
<script>
for(let elem of document.querySelectorAll('*'))
{
elem.addEventListener("click",
e => alert(`Capturing: ${elem.tagName}`), true);
elem.addEventListener("click",
e => alert(`Bubbling: ${elem.tagName}`));
}
</script>
The "$" symbol is a place holder for the text (parameters) passed to a function. In the example above the message to be displayed in the alert() box function. In this case when the event was Capturing or Bubbling and the element tagname
The code for the function to control a timed modal
<script>
$(document).ready(function(){
$('#modal').click(function(){
$('#exampleModal').modal('show');
setTimeout(function() {$('#exampleModal').modal('hide');},
2000);
});
});
</script>
The function above is a little more complex.
The data-toggle parameter
geeksforgeeks.org say:
There is also a Stack Overfow thread for this but I think that it talks around the subject. The a better understanding I think you need to look at the Bootstrap documentation.
Links