希望支持.cjs 扩展名的编译
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 18.6k
- Forks
- 2.1k
- PR merge metrics
- No merged PRs in 30d
Description
### Describe the bug
我项目里引入了animejs包,它的模块解析链路是dist/modules/index.cjs,因为compileDependencies不支持.cjs文件的转义,在一些低版本手机比如iphone12里一些高级语法比如可选链 `?.`就无法执行会报错
### Expected behavior
ice3 框架支持.cjs 扩展名的编译
### Actual behavior
_No response_
### Version of ice.js
3.4.10
### Content of build.json or ice.config.mts
```TypeScript
```
### Additional context
_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 at the compileDependencies entry point and reproduce the issue with animejs resolving to dist/modules/index.cjs. Check the build behavior for optional chaining on the reported older iPhone environment, and consider the work complete when .cjs dependencies are compiled and the resulting code executes there.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- build-system
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 50/100