-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
(void 0) is not a function #9
Comments
我找到了另一种汉化的解决方案 <template>
<div ref="divRef" style="height: 500px; width: 500px"></div>
</template>
<script lang="ts" setup>
import loader from "@monaco-editor/loader";
import * as monaco from "monaco-editor";
const divRef = ref();
loader.config({ monaco });
loader.config({
"vs/nls": {
// availableLanguages: { "*": "de" },
availableLanguages: { "*": "zh-cn" },
},
});
loader.init().then(monacoInstance => {
monacoInstance.editor.create(divRef.value, {
value: "321313123",
});
});
</script>
<style lang="scss"></style>
|
你这还引入monaco干嘛,走的是cdn,不信你开审查元素看看。。。我已经试过了 |
同样的问题 |
这种方法没有走cdn吧,走的本地npm |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
依赖
配置
报错
The text was updated successfully, but these errors were encountered: