opentiny / opentiny/tiny-editor
🐛 [Bug]: Angular17+Jest 环境下,执行 jest 单元测试会报错:Quill.import is not a function
Open
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 535
- Forks
- 71
- Avg merge
- 6h 50m
- Merged PRs (30d)
- 2
Description
Version
latest
Link to minimal reproduction
使用 Angular CLI 创建一个 Angular 17 项目,引入 TinyEditor 富文本编辑器,集成 Jest 单元测试框架,测试用例中初始化 TinyEditor 实例(new TinyEditor(xxx)),执行 jest 单元测试会报错。
Step to reproduce
如上
What is expected
No response
What is actually happening
No response
What is your project name
Wiki
Any additional comments (optional)
No response
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the Angular CLI reproduction described in the issue: create an Angular 17 project, integrate TinyEditor and Jest, then initialize TinyEditor in a test. Trace the Quill import used during initialization and compare its Jest behavior with the supported Quill 2.0 setup. Done means the Jest test initializes TinyEditor without the “Quill.import is not a function” error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- angular, typescript
- Domain
- frontend, testing-qa
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100