https://github.com/bitfumes/bridge-svelte-notification
Customisable and easy notifications system for svelte users
https://github.com/bitfumes/bridge-svelte-notification
Last synced: 4 months ago
JSON representation
Customisable and easy notifications system for svelte users
- Host: GitHub
- URL: https://github.com/bitfumes/bridge-svelte-notification
- Owner: bitfumes
- Created: 2020-04-17T14:28:08.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2020-04-17T20:12:30.000Z (about 6 years ago)
- Last Synced: 2025-07-18T19:19:09.005Z (11 months ago)
- Language: HTML
- Size: 3.91 KB
- Stars: 1
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Bridge Notifications

## Demonstration
[https://bridge-notification.netlify.app](https://bridge-notification.netlify.app)
## Getting started
```bash
npm install --save bridge-svelte-notification
```
## Basic usage
```javascript
// App.svelte
import BridgeNotify from "bridge-svelte-notification";
<main>
<BridgeNotify />
...
</main>
```
```javascript
// ChildrenComponent.svelte
import { notify } from "bridge-svelte-notification";
function show(position) {
notify({
message: "Bridge Notification is Awesome 😍",
type: 'success',
duration: 3000,
position: 'center',
animate: {
y: 100,
x: 0,
duration: 500
}
});
}
Show Notification
```
## Providing custom style component
```javascript
// ChildrenComponent.svelte
import { notify } from "bridge-svelte-notification";
function show(position) {
notify({
message: "Bridge Notification is Awesome 😍",
type: 'success',
duration: 3000,
position: 'center',
animate: {
y: 100,
x: 0,
duration: 500
},
style:'backgound-color:blue;color:black'
});
}
Show Notification
```