Giter Club home page Giter Club logo

reveal-yaml-rs's Introduction

Reveal.yaml

dependency status Documentation

Rust implementation of Reveal.js YAML server, a command line interface (CLI) tool.

This manager downloads the latest Reveal.js archive to provide serving and packing function, and had same licensed as Reveal.js.

Static demo on gh-pages: https://kmolyuan.github.io/reveal-yaml-rs

YAML 1.2 backend: https://github.com/KmolYuan/yaml-peg-rs (hosted by myself)

What is YAML? YAML is a structural language that can simply represent sequence and map data structures with indent syntax. YAML also has some inline syntax that is compatible with non-strict JSON language.
What is the old Python version? This project is transferred from Python language, so you may found it on PyPI. Reveal.yaml is now operates in a way that is easier to maintain and release, and it is Rust. Some old functions might be deprecated, and some functions are improved.

Why should I use this?

Source Output
YAML + media (Images / Videos) HTML Slide (static) / Showcase

Have you ever using Reveal.js with Markdown, but it is still difficult to maintain HTML slideshows? This work provides a clean YAML file for your slides, an auto-generated outline, a simple layout function, a powerful support with original Reveal.js function, and a live presentation when editing.

Difference to the before work, the Markdown to HTML translation works by this parser instead of using markdown.js, so there is no more HTML escaping since they will be handled enough. Except for using Markdown recursively in your code block, this needs to use the <code> tags by yourself.

If you are not decide yet, see the documentation for more information.

Installation

Download CLI executable from GitHub release: https://github.com/KmolYuan/reveal-yaml-rs/releases/

Wherever the binary placed, it should be visible for the environment variable PATH.

If you are a Rust user, install it with cargo is possible. Unfortunately, the binary is build with the cargo toolchain, and you will get a large size than the CI/CD result.

# Ensure openssl headers are installed in Ubuntu
sudo apt install libssl-dev
cargo install reveal-yaml

It recommends download GitHub distribution directly for saving your time. For example, a CI/CD script can write as:

wget -O reveal-yaml.zip https://github.com/KmolYuan/reveal-yaml-rs/releases/latest/download/reveal-yaml-linux-amd64.zip
unzip reveal-yaml.zip
chmod +x rym
./rym pack

The executable can be checked with rym command.

Command Line Interface

The command rym stands for "Reveal-Yaml Manager".

Command Description
help Show the CLI help message
update Download the Reveal.js resources
new Create a new project and its directory
init Create a new project from an existing directory
serve Serve the current project
fmt Format the current project
pack Pack the current project

Please see rym --help/rym subcommand --help for more information.

Edit Mode (Hot Reload / Auto-reload)

There are -e/--edit flags on the serve command. This option let the server keep watching the project file reveal.yaml, then reload the page from the web browser. (via JS & WebSocket)

If this option is not enabled, the server will only resolve once at startup, and always use the cache.

rym serve --edit

reveal-yaml-rs's People

Contributors

kmolyuan avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

reveal-yaml-rs's Issues

Would it be a way to show local images ?

Hello @KmolYuan

I'm looking for a way to include static assets locally like img, gifs ...

I don't see any example where it's possible, not in the sources, but perhaps I just didn't seek enough ?

So is there a way ?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.