Skip to content

Instantly share code, notes, and snippets.

@Akii
Created May 6, 2015 08:13
Show Gist options
  • Save Akii/4d7626d0f22f8f1c5d90 to your computer and use it in GitHub Desktop.
Save Akii/4d7626d0f22f8f1c5d90 to your computer and use it in GitHub Desktop.
{{textarea value=markdown rows="10" class="form-control"}}
import Ember from 'ember';
export default Ember.Component.extend({
init: function() {
this._super();
// Showdown is available
/* jshint ignore:start */
this.set('showdownConverter', new Showdown.converter());
/* jshint ignore:end */
},
whereYouWouldInitJqueryStuff: function() {
//this.$('.yourInput').tagsInput();
}.on('didInsertElement')
// striped some unimportant code here, basically this component shows a preview of rendered markdown
});
{{mark-down markdown=model.description}}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment