diff --git a/app/javascript/application.js b/app/javascript/application.js index 65e1c18..1c44cf7 100644 --- a/app/javascript/application.js +++ b/app/javascript/application.js @@ -1,16 +1,10 @@ // Configure your import map in config/importmap.rb. Read more: https://github.com/rails/importmap-rails import "@hotwired/turbo-rails" import "controllers" -import { Notyf } from 'notyf' -window.buildNotyf = ()=>{ - const notyf=new Notyf({ - duration: 5000, - position: { x: 'center', y: 'top' }, - }) - return notyf -} +// Notyf +import { Notyf } from 'notyf' +window.Notyf=Notyf // Customize Turbo default behaviour -Turbo.setProgressBarDelay(300) -// Turbo.session.drive = false \ No newline at end of file +Turbo.setProgressBarDelay(300) \ No newline at end of file diff --git a/app/views/layouts/_notification.html.erb b/app/views/layouts/_notification.html.erb index d5db2e7..d88e46d 100644 --- a/app/views/layouts/_notification.html.erb +++ b/app/views/layouts/_notification.html.erb @@ -1,13 +1,14 @@ -