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

2.6.0 • 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

97

Version

2.6.0

License

MIT

Unpacked Size

490 kB

Total Files

38

Last publish

Collaborators

  • pecka
  • zipper.cze
  • jan.kaderabek