AngularJS directive for snap.js