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

@webwriter/slides

v2.3.0

Published

Present content as a sequence of slides or tabs.

Downloads

136

Readme

Slides (@webwriter/[email protected])

License: MIT | Version: 2.3.0

Present content as a sequence of slides or tabs.

Snippets

Snippets are examples and templates using the package's widgets.

| Name | Import Path | | :--: | :---------: | | Example | @webwriter/slides/snippets/example.html |

WebwriterSlides (<webwriter-slides>)

Container for displaying a slideshow of content sequentially.

Usage

Use with a CDN (e.g. jsdelivr):

<link href="https://cdn.jsdelivr.net/npm/@webwriter/slides/widgets/webwriter-slides.css" rel="stylesheet">
<script type="module" src="https://cdn.jsdelivr.net/npm/@webwriter/slides/widgets/webwriter-slides.js"></script>
<webwriter-slides></webwriter-slides>

Or use with a bundler (e.g. Vite):

npm install @webwriter/slides
<link href="@webwriter/slides/widgets/webwriter-slides.css" rel="stylesheet">
<script type="module" src="@webwriter/slides/widgets/webwriter-slides.js"></script>
<webwriter-slides></webwriter-slides>

Fields

| Name (Attribute Name) | Type | Description | Default | Reflects | | :-------------------: | :--: | :---------: | :-----: | :------: | | activeSlideIndex | number | Index of the currently active slide. | 0 | ✗ | | activeSlide | WebwriterSlide | The active slide element based on the activeSlideIndex. | - | ✗ | | type (type) | 'tabs' \| 'slides' | Defines the type of view for the slideshow.- "slides": Show content as sequential slides.- "tabs": Show content using tabs. | 'slides' | ✓ | | hasNextSlide | boolean | False if slideshow is on the last slide. | - | ✗ | | hasPreviousSlide | boolean | False if slideshow is on the first slide. | - | ✗ |

Fields including properties and attributes define the current state of the widget and offer customization options.

Methods

| Name | Description | Parameters | | :--: | :---------: | :-------: | | _handleKeyDown | Handles keyboard navigation for the slideshow.ArrowRight advances to the next slide, ArrowLeft goes back.Only possible in preview mode. | e: KeyboardEvent | addSlide | Add a new empty slide element. Optionally insert after given index. | index: number | duplicateSlide | Duplicate an existing slide at given index. | index: number | removeActiveSlide | Remove the currently active slide element. | - | removeSlide | Remove the currently active slide element. | slideIndex: number | nextSlide | Activate the next slide element. | backwards=false, step=1

Methods allow programmatic access to the widget.

Slots

| Name | Description | Content Type | | :--: | :---------: | :----------: | | default | Slide elements to be displayed (should be webwriter-slide components only). | webwriter-slide+ |

Slots define how the content of the widget is rendered.

Editing config

| Name | Value | | :--: | :---------: | | definingAsContext | true | | definingForContent | true | | content | webwriter-slide+ |

The editing config defines how explorable authoring tools such as WebWriter treat the widget.

No public events, custom CSS properties, or CSS parts.

WebwriterSlide (<webwriter-slide>)

Represents a single slide in the webwriter-slides widget.

Usage

Use with a CDN (e.g. jsdelivr):

<link href="https://cdn.jsdelivr.net/npm/@webwriter/slides/widgets/webwriter-slide.css" rel="stylesheet">
<script type="module" src="https://cdn.jsdelivr.net/npm/@webwriter/slides/widgets/webwriter-slide.js"></script>
<webwriter-slide></webwriter-slide>

Or use with a bundler (e.g. Vite):

npm install @webwriter/slides
<link href="@webwriter/slides/widgets/webwriter-slide.css" rel="stylesheet">
<script type="module" src="@webwriter/slides/widgets/webwriter-slide.js"></script>
<webwriter-slide></webwriter-slide>

Fields

| Name (Attribute Name) | Type | Description | Default | Reflects | | :-------------------: | :--: | :---------: | :-----: | :------: | | active (active) | boolean | Indicates whether the slide is currently active/visible. | false | ✓ | | thumbnail (thumbnail) | string | Data URI string for the slide thumbnail (e.g., "data:image/png;base64,...").Used to display a preview image for the slide. | "" | ✓ |

Fields including properties and attributes define the current state of the widget and offer customization options.

Slots

| Name | Description | Content Type | | :--: | :---------: | :----------: | | default | The content displayed within the slide. | p | flow* |

Slots define how the content of the widget is rendered.

Editing config

| Name | Value | | :--: | :---------: | | definingAsContext | true | | definingForContent | true | | content | p \| flow* | | uninsertable | true |

The editing config defines how explorable authoring tools such as WebWriter treat the widget.

No public methods, events, custom CSS properties, or CSS parts.


Generated with @webwriter/[email protected]