mirror of
https://github.com/discourse/discourse.git
synced 2025-05-25 09:57:25 +08:00
DEV: Use esbuild to make DiscourseJsProcessor (#23223)
Reverts e2705df and re-lands #23187 and #23219. The issue was incorrect order of execution of Rails' `assets:precompile` task in our own precompilation stack. Co-authored-by: David Taylor <david@taylorhq.com>
This commit is contained in:
@ -281,12 +281,11 @@ class Compiler {
|
||||
}
|
||||
}
|
||||
|
||||
// eslint-disable-next-line no-undef
|
||||
const loader = typeof Ember !== "undefined" ? Ember.__loader.require : require;
|
||||
const defaultGlimmer = require("@glimmer/syntax");
|
||||
|
||||
function compile(template, glimmer) {
|
||||
if (!glimmer) {
|
||||
glimmer = loader("@glimmer/syntax");
|
||||
glimmer = defaultGlimmer;
|
||||
}
|
||||
const compiled = glimmer.preprocess(template);
|
||||
const compiler = new Compiler(compiled);
|
||||
|
Reference in New Issue
Block a user