📜  livewire 进度指示器 javascript 代码示例

📅  最后修改于: 2022-03-11 15:02:09.680000             🧑  作者: Mango

代码示例1
window.addEventListener('livewire-upload-start', event => {
  console.log('upload started');
});
window.addEventListener('livewire-upload-finished', event => {
  console.log('upload finished');
});
window.addEventListener('livewire-upload-error', event => {
  console.log('upload error');
});
window.addEventListener('livewire-upload-progress', event => {
  console.log(`${event.detail.progress}%`);
});