An open API service indexing awesome lists of open source software.

https://github.com/dashpilot/tiny-modal-web-component

A tiny modal web component made with Svelte
https://github.com/dashpilot/tiny-modal-web-component

Last synced: 4 months ago
JSON representation

A tiny modal web component made with Svelte

Awesome Lists containing this project

README

          

# tiny-modal-web-component

Lightweight modal web component made with Svelte

## Demo

## Usage

Grab the files from CDN:
```

```

Then just slot the modal-content within the web component, like so:


This is some modal content

To launch the modal, just add a data-attribute of `data-show="{id-of-modal}"` to your launch-button:

Launch Modal

To prevent the modal content from flashing onto the screen on page load, add the following style to your CSS:

tiny-modal{
display: none;
}