wip: ajax notifications w/ php-flasher
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import { Controller } from '@hotwired/stimulus';
|
||||
|
||||
import flasher from '@flasher/flasher'
|
||||
/*
|
||||
* The following line makes this controller "lazy": it won't be downloaded until needed
|
||||
* See https://github.com/symfony/stimulus-bridge#lazy-controllers
|
||||
@@ -31,7 +31,7 @@ export default class extends Controller {
|
||||
})
|
||||
.then(res => res.json())
|
||||
.then(json => {
|
||||
console.log(json)
|
||||
})
|
||||
flasher.success(json.message);
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user