discourse/app/assets/javascripts/admin/components/highlighted-code.js.es6

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

12 lines
322 B
Plaintext
Raw Normal View History

import Component from "@ember/component";
import { on, observes } from "discourse-common/utils/decorators";
import highlightSyntax from "discourse/lib/highlight-syntax";
export default Component.extend({
@on("didInsertElement")
@observes("code")
_refresh: function() {
highlightSyntax($(this.element));
}
});