@peckadesign/pd-modal
TypeScript icon, indicating that this package has built-in type declarations

2.5.1 • Public • Published

pd-modal

Quick start

$ npm install @peckadesign/pd-modal
import { PdModal, HTMLContentLoader } from '@peckadesign/pd-modal'

const modal = new PdModal()
modal.registerContentLoader(new HTMLContentLoader())

This code will create instance of a modal window. The content itself is loaded using content loaders. This allows you to import only loaders you actually need in your project.

When HTMLContentLoader is registered, the modal is automatically binded to link elements with class="js-modal" by default. For more in-depth info and complete documentation, please see example.

Package Sidebar

Install

npm i @peckadesign/pd-modal

Weekly Downloads

9

Version

2.5.1

License

MIT

Unpacked Size

486 kB

Total Files

38

Last publish

Collaborators

  • pecka
  • zipper.cze
  • jan.kaderabek