@ppci-mock/global-error

1.1.22 • Public • Published

Global Error

Table of contents

  1. Installation
  2. Usage
  3. Properties
  4. Events

Installation

NPM

npm i @ppci-mock/global-error

// Polyfill: https://lit-element.polymer-project.org/guide/use#polyfills
npm i --save-dev @webcomponents/webcomponentsjs

Usage

Javascript

import '@ppci-mock/global-error'

Browser

<!-- Default -->
<script type="module" src="https://cdn.jsdelivr.net/npm/@ppci-mock/global-error/builds/index.min.js" />

<!-- Legacy -->
<script type="module" src="https://cdn.jsdelivr.net/npm/@ppci-mock/global-error/builds/legacy.min.js" />

<!-- Component -->
<global-error
  title=${String}
  message=${String}
  retryTitle=${String}
  @onRetry=${Event}
></global-error>

Properties

Property Type Description Possible Values
*title* string Title of the notification
message string Error description message
retryTitle string Title of the retry button. Button will not appear if retryTitle is empty
retryAction Function Title of the retry button. Button will not appear if retryTitle is empty

Events

Name Description Payload
@onRetry Triggered when the retry button is clicked

Readme

Keywords

Package Sidebar

Install

npm i @ppci-mock/global-error

Weekly Downloads

0

Version

1.1.22

License

ISC

Unpacked Size

6.3 kB

Total Files

6

Last publish

Collaborators

  • fsevenhuysen
  • borai
  • franksevenhuysen