dom111 / melba

Tiny Toast library

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

melba-toast - A tiny toast library

My focus for making this was to have a minimal toast that can easily be extended as necessary. The styling is currently minimal but that is by design and the aim would be for users to augment the styles and theme as necessary.

Installation

yarn add melba-toast

or

npm i melba-toast

Usage

import Melba from 'melba-toast';

const toast = new Melba({
    content: 'Testing',
    type: 'error'
});

See src/Melba.ts for additional options that can be passed in.

Be sure to load the styles too:

/* SCSS */
@import '~melba-toast';

About

Tiny Toast library

License:MIT License


Languages

Language:TypeScript 77.5%Language:SCSS 16.1%Language:JavaScript 6.4%