Como adicionar o seletor de datas ou qualquer plug-in jQuery geral ao aplicativo Ember-CLI
Então, eu estou tentando adicionarpikaday
seletor de datas para o aplicativo Ember-CLI.
Eu tenho o seguinte na minha/app/views/calendar-view.js
import Ember from 'ember';
export default Ember.TextView.extend({
modelChangedValue: function(){
console.log(this.get('value'));
}.observes("value"),
didInsertElement: function(){
currentYear = (new Date()).getFullYear();
formElement = this.$()[0];
picker = new Pikaday({
field: formElement,
yearRange: [1900,currentYear+2]
});
this.set("_picker", picker);
},
willDestroyElement: function(){
picker = this.get("_picker");
if (picker) {
picker.destroy();
}
this.set("_picker", null);
}
});
Meu problema principal é como adicionar o próprio plugin ao ember-cli?
Este é o link do github para o pikaday:https://github.com/dbushell/Pikaday
Mais especificamente, acho que essa parte pode ser importante, pois o Ember-CLI usa AMD:https://github.com/dbushell/Pikaday#amd-support
Então, como adiciono o próprio plugin ao ember-cli?