Files
NexQuant/web/src/components/kateX.vue
T
XianBW 14395488b9 feat: add a web UI server (#1345)
* update rdagent cmd

* fix log error message

* use multiProcessing.Process instead of subprocess.Popen

* add traces to gitignore

* add user interactor in RDLoop (finance scenarios)

* add interactor (feedback, hypothesis) for quant scens

* fix the test_end in qlib conf

* add features init config, general instruction to qlib scenarios

* set base features for based exp

* fix bug when combine factors

* move traces folder to git_ignore_folder

* fix bug in features init

* fix quant interact bug

* fix logger warning error

* bug fixes

* modify rdagent logger, now it can set file output

* adjust cli functions and fix logger bug

* fix server port transport problem

* update server_ui in cli

* add web code

* fix CI problem

* black fix

* update web ui README

* update README

* update readme
2026-03-18 14:04:52 +08:00

37 lines
780 B
Vue

<template>
<div class="math-box" ref="katexContainer"></div>
</template>
<script setup>
import { ref, watch, onMounted, defineProps } from "vue";
import "katex/dist/katex.min.css";
import katex from "katex";
const props = defineProps({
formula: String,
});
const katexContainer = ref(null);
watch(
() => props.formula,
(newValue, oldValue) => {
katex.render(newValue, katexContainer.value, {
throwOnError: false, // 避免在公式错误时抛出异常
});
}
);
onMounted(() => {
if (katexContainer.value) {
katex.render(props.formula, katexContainer.value, {
throwOnError: false, // 避免在公式错误时抛出异常
});
}
});
</script>
<style scoped lang="scss">
.math-box {
display: flex;
justify-content: center;
}
</style>