revealjs is a JavaScript library for creating beautiful and interactive presentations using HTML. In this tutorial, we will cover how to install revealjs on Void Linux.
Before you begin, make sure you have the following:
sudo xbps-install -S
sudo xbps-install -y nodejs
mkdir my-presentation
cd my-presentation
npm install reveal.js@4.2.0
Note: The version number may change in the future. You can check the latest version on the revealjs homepage.
touch index.html
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>My Presentation</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="node_modules/reveal.js/dist/reveal.css">
<link rel="stylesheet" href="node_modules/reveal.js/dist/theme/white.css">
<!-- Theme used for syntax highlighting of code -->
<link rel="stylesheet" href="node_modules/reveal.js/plugin/highlight/monokai.css">
<!-- Printing and PDF exports -->
<script type="text/javascript" src="node_modules/reveal.js/plugin/print-pdf/print-pdf.js"></script>
<!--[if lt IE 9]>
<script src="https://cdnjs.cloudflare.com/ajax/libs/html5shiv/3.7.3/html5shiv.js"></script>
<![endif]-->
</head>
<body>
<div class="reveal">
<div class="slides">
<section>
<h1>Hello, World!</h1>
</section>
</div>
</div>
<script src="node_modules/reveal.js/dist/reveal.js"></script>
<script>
// More info about config & dependencies:
// - https://revealjs.com/config/
// - https://revealjs.com/dependencies/
Reveal.initialize({
hash: true,
plugins: [ RevealHighlight, RevealNotes, RevealMath ],
keyboard: {13: 'next'}
});
</script>
</body>
</html>
Note: This is a basic example. For more information on creating presentations using revealjs, check out the official documentation.
sudo sv start nginx
http://localhost/my-presentation/index.html
.Congratulations! You have successfully installed revealjs on Void Linux and created your first presentation using revealjs.
If you want to self-host in an easy, hands free way, need an external IP address, or simply want your data in your own hands, give IPv6.rs a try!
Alternatively, for the best virtual desktop, try Shells!