Skip to content

Instantly share code, notes, and snippets.

@selbyk
Created March 19, 2016 21:38
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save selbyk/7cfbf432e97f2c2154c8 to your computer and use it in GitHub Desktop.
Save selbyk/7cfbf432e97f2c2154c8 to your computer and use it in GitHub Desktop.
import Ember from 'ember';
export default Ember.Component.extend({
tagName: 'audio',
attributeBindings: ['src', 'preload'],
src: Ember.computed.alias('url'),
preload: 'none',
didInsertElement() {
let _this = this;
audiojs.events.ready(function() {
_this.set('as', audiojs.create(_this.get('element')));
});
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment