npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@mbertogliati/docsify-slide-presentation

v1.1.2

Published

Lightweight in-page slides plugin for Docsify using simple markers (no external dependency)

Readme

Docsify Slide Presentation Plugin

A lightweight, zero-dependency Docsify plugin that lets you create inline slide decks inside any Markdown page using simple HTML comment markers.

  • Lightweight, no external dependency
  • Works inline in any Markdown page
  • Keyboard support (Left/Right)

Features

  • Create slides using markers inside Markdown
  • Navigation controls and keyboard support
  • Works out of the box with Docsify
  • Optional Mermaid.js integration (if present on the page)

Markers

Use these markers in your Markdown to define slides:

  • <!-- slide:start --> to begin a slide deck
  • <!-- slide:break --> to split slides
  • <!-- slide:end --> to finish the deck

Example:

<!-- slide:start -->
# Product Onboarding

Welcome to the new slides component. Use the buttons or arrow keys to navigate.

- Lightweight, no external dependency
- Works inline in any Markdown page
- Keyboard support (Left/Right)

<!-- slide:break -->

## Step 1: Install
Nothing to install — it's already bundled. Just use the markers:

- `<!-- slide:start -->` to begin
- `<!-- slide:break -->` to split slides
- `<!-- slide:end -->` to finish

<!-- slide:break -->

## Step 2: Add Content
You can include lists, images, code, and diagrams.

```js
// Code runs fine inside slides
console.log('Hello Slides!');

## Installation

You can use this plugin via CDN (script tag) or install it from npm for bundlers.

### Option A: CDN (recommended)

Add the plugin and CSS in your Docsify `index.html`:

```html
<!-- Docsify core -->
<script src="https://cdn.jsdelivr.net/npm/docsify@4"></script>

<!-- Slides plugin -->
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/docsify-slide-presentation/dist/slides.css">
<script src="https://cdn.jsdelivr.net/npm/docsify-slide-presentation/dist/slides.js"></script>

The plugin auto-registers itself with Docsify when loaded.

Option B: npm (for bundlers)

npm install docsify-slide-presentation
# or
pnpm add docsify-slide-presentation
# or
yarn add docsify-slide-presentation

Then import the UMD build in your app (if you embed Docsify programmatically):

import DocsifySlides from 'docsify-slide-presentation/dist/slides.umd.js';

if (window.$docsify) {
  window.$docsify.plugins = [DocsifySlides].concat(window.$docsify.plugins || []);
}

Or, if your bundler auto-exposes globals, you can also rely on the auto-install behavior of the UMD build (it will register itself if window.$docsify exists).

Configuration

You can customize behavior via $docsify.slidesOptions (or $docsify.slides, both supported):

<script>
  window.$docsify = {
    name: 'My Docs',
    // ...
    slidesOptions: {
      height: 420,       // number (px) - viewport height inside the slide deck
      overflow: 'auto',  // 'auto' | 'scroll' | 'clip' - fallback for both axes
      overflowX: 'auto', // optional per-axis overrides
      overflowY: 'auto'
    }
  };
</script>

Notes:

  • overflow: 'clip' maps to overflow: hidden to avoid scrollbars.
  • When changing slides, the viewport scroll position resets to top-left.
  • Mermaid diagrams inside slides are automatically initialized if window.mermaid is present.

Mermaid Support (optional)

If you include Mermaid on the page, the plugin will detect and render diagrams inside slides.

<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/docsify-slide-presentation/dist/slides.css">
<script src="https://cdn.jsdelivr.net/npm/mermaid@10/dist/mermaid.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/docsify-slide-presentation/dist/slides.js"></script>

You can write Mermaid as fenced code blocks with language-mermaid or as <div class="mermaid">.

Example

A complete example is available in examples/index.html. You can open it using a static server. For a quick local test:

npx serve examples

Then visit the printed local URL and navigate the slides.

Development

  • Source files (source of truth): src/slides.js, src/slides.css
  • Distributables: dist/slides.js, dist/slides.css, dist/slides.umd.js

Edit files under src/ and then update/copy builds into dist/ before publishing. If you prefer a build step, you can add Rollup or esbuild later.

License

MIT. See LICENSE.