codesandbox / codesandbox/codesandbox-client
Could not find/install babel plugin 'proposal-decorators'
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 13.6k
- Forks
- 2.4k
- Avg merge
- 6d 19h
- Merged PRs (30d)
- 2
Description
🐛 bug report
Preflight Checklist
- I have read the Contributing Guidelines for this project.
- I agree to follow the Code of Conduct that this project
adheres to. - I have searched the issue tracker for an issue that matches the one I want
to file, without success.
Description of the problem
Example with an SVG import is resulting in an error:
Error
Could not find/install babel plugin 'proposal-decorators': Cannot find plugin 'proposal-decorators' or 'babel-plugin-proposal-decorators'
This is happening when deploying with react-codesandboxer.
Removing the SVG imports resolves the issue, as does fiddling with dependencies.
After deploying, manually adding @babel/plugin-proposal-decorators as a dependency resolves the issue. Deploying with @babel/plugin-proposal-decorators as a dependency does not, but then removing it seems to.
How has this issue affected you? What are you trying to accomplish?
The example I have deployed is unusable.
To Reproduce
I struggled to create a minimal reproduction, but I will share the sandboxes I am seeing the issue in.
Link to sandbox:
- Example deployed without
@babel/plugin-proposal-decorators- Adding
@babel/plugin-proposal-decoratorsseems to fix the issue
- Adding
- Example deployed with
@babel/plugin-proposal-decorators- Removing
@babel/plugin-proposal-decoratorsseems to fix the issue
- Removing
Your Environment
| Software | Name/Version |
|---|---|
| Сodesandbox | ? |
| Browser | Chrome 115 |
| Operating System | MacOS Ventura 13.4.1 |
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 two linked sandboxes and the react-codesandboxer deployment path, comparing the cases with and without @babel/plugin-proposal-decorators. Investigate how SVG imports trigger installation of the proposal-decorators plugin. Done means deployments no longer fail with the missing-plugin error without manual dependency changes.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- babel, javascript, react
- Domain
- build-system, frontend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100