
# Requirements
vue version >=3.2.0
# Installation
```bash
npm install --save vue3-toastify
# yarn add vue3-toastify
```
# Demo
[A demo is worth a thousand words](https://vue3-toastify.js-bridge.com)
[备用地址](https://vue3-toastify.netlify.app)
# Document
Check the [documentation](https://vue3-toastify.js-bridge.com/get-started/introduction.html) to get you started!
[备用地址](https://vue3-toastify.netlify.app/get-started/introduction.html)
# The gist
```html
```
## Init/Update Global Props
```ts
// main.ts
import Vue3Toastify, { type ToastContainerOptions } from 'vue3-toastify';
app.use(Vue3Toastify, {
autoClose: 3000,
} as ToastContainerOptions);
```
```js
// tsconfig.json
{
"compilerOptions": {
"types": [
"vue3-toastify/global"
]
}
}
```
or
```ts
updateGlobalOptions({ rtl: true });
toast.success('Wow so easy!');
```
## nuxt
[A nuxt demo](https://stackblitz.com/edit/nuxt-starter-1gszqs?file=app.vue,plugins%2Fvue3-toastify.ts)
- plugins/vue3-toastify.ts
```ts
import Vue3Toastify, { toast } from 'vue3-toastify';
import 'vue3-toastify/dist/index.css';
export default defineNuxtPlugin((nuxtApp) => {
nuxtApp.vueApp.use(Vue3Toastify, { autoClose: 1000 });
return {
provide: { toast },
};
});
```
- demo.vue
```html
```
## Using the ES Module Build
[jsfiddle demo](https://jsfiddle.net/jerrywu001/r42xous5/)
```html
Using the ES Module Build
```
## Sponsors
Special Sponsor