BookStack/resources/js/components/code-textarea.js

15 lines
350 B
JavaScript
Raw Normal View History

/**
* A simple component to render a code editor within the textarea
* this exists upon.
*/
2022-11-15 20:44:57 +08:00
import {Component} from "./component";
export class CodeTextarea extends Component {
async setup() {
const mode = this.$opts.mode;
const Code = await window.importVersioned('code');
Code.inlineEditor(this.$el, mode);
}
}