adrema/resources/livewire-js/app.js

25 lines
655 B
JavaScript
Raw Normal View History

2024-10-14 20:25:11 +02:00
import {Livewire, Alpine} from '../../vendor/livewire/livewire/dist/livewire.esm';
import Tooltip from '@ryangjchandler/alpine-tooltip';
2024-10-13 21:00:47 +02:00
import '../css/app.css';
2024-10-14 20:25:11 +02:00
import 'tippy.js/dist/tippy.css';
import 'tippy.js/animations/shift-toward.css';
import '../css/tooltip.css';
import {error, success} from './toastify.js';
2024-12-22 18:34:00 +01:00
import editor from './editor.js';
2024-10-14 20:25:11 +02:00
Alpine.plugin(
Tooltip.defaultProps({
theme: 'primary',
animation: 'shift-toward',
})
);
window.addEventListener('success', (event) => success(event.detail[0]));
2024-12-22 18:34:00 +01:00
document.addEventListener('alpine:init', () => {
Alpine.bind('editor', () => editor);
});
2024-10-14 20:25:11 +02:00
Livewire.start();