Files
David TaylorandGitHub 53bcd699a0 DEV: Update remaining core plugin components to native-class syntax (#28611)
Changes made using the ember-native-class-codemod, plus some manual tweaks
2024-08-29 12:16:52 +01:00

13 lines
365 B
JavaScript

import Component from "@ember/component";
import $ from "jquery";
import { cook } from "discourse/lib/text";
export default class StyleguideMarkdown extends Component {
didInsertElement() {
super.didInsertElement(...arguments);
const contents = $(this.element).html();
cook(contents).then((cooked) => $(this.element).html(cooked.toString()));
}
}