Updated directives.js