使用UMD方式引入,代码出不来,控制台报错:require is not defined
- Vorherrschende Sprache
- TypeScript
- Sterne
- 1.5k
- Forks
- 83
- PR-Merge-Kennzahlen
- Keine gemergten PRs in 30 T.
Beschreibung
**Describe the bug**
完全拷贝以下文档中 UMD 方式使用的代码:
https://github.com/petercat-ai/petercat/blob/main/docs/guides/quick_%20assistant_start_cn.md
先引入以下代码:
```
```
再引入以下代码:
```
...
PetercatLUI.initAssistant({
apiDomain: 'https://api.petercat.ai',
token: 'your-token',
starters: ['介绍下这个项目', '查看贡献指南', '我该怎样快速上手'],
clearMessage: true
});
```
代码显示不出来,控制台报错:

**To Reproduce**
复现链接:https://opentiny.github.io/tiny-vue/
提问输入框中问以下问题:怎么使用tree-menu组件,给出示例代码
即可复现。
**Expected behavior**
A clear and concise description of what you expected to happen.
**Screenshots**
If applicable, add screenshots to help explain your problem.
**Desktop (please complete the following information):**
- OS: [e.g. iOS]
- Browser [e.g. chrome, safari]
- Version [e.g. 22]
**Additional context**
Add any other context about the problem here.
Beitragsleitfaden
Für dieses Repository ist kein Beitragsleitfaden indexiert
Bewertung
Dieses Issue wurde noch nicht bewertet.