import { ref } from 'vue';

export const toastMessage = ref(null);

/**
 * @param {'success' | 'info' | 'danger' | 'warning'} type 
 * @param {string} message 
 */
export function showToast(type, message) {
    toastMessage.value = {
        type: String(type),
        message: String(message),
    };
}