JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • 0
  • Score
    100M100P100Q25076F
  • License ISC

Global error

Package Exports

  • @ppci/global-error

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@ppci/global-error) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

Global Error

Table of contents

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

Installation

NPM

npm i @ppci/global-error

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

Usage

Javascript

import '@ppci/global-error'

Browser

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

<!-- Legacy -->
<script type="module" src="https://cdn.jsdelivr.net/npm/@ppci/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