Update src/directives/alert.js

adding feature where alert can be reused