Error when trying to launch a project for local development
Q&A (please complete the following information)
- OS: windows 10
- Browser: chrome
- Version: 130
- Method of installation: npm
- Swagger-Editor version: 5.0.0-alpha.96
Content & configuration
I am trying to run swagger-editor-next locally I followed the startup instructions:
$ git submodule init
$ git submodule update
$ npm i
$ npm start
and I got an error:
ERROR in ./src/plugins/editor-monaco/components/MonacoEditor/MonacoEditor.jsx 8:0-40
Module not found: Error: You attempted to import /node_modules/monaco-editor which falls outside of the project src/ directory. Relative imports outside of src/ are not supported.
You can either move it inside src/, or add a symlink to it from project's node_modules/.
I also checked:
npm ls monaco-editors
[email protected] C:\Users\zhivovi\develop\swagger-editor
+-- monaco-editor@npm:@codingame/[email protected]
`-- [email protected] -> .\create-react-app\packages\react-scripts
`-- monaco-editor@npm:@codingame/[email protected] deduped
And I tried npm dedupe but the mistake remained the same
I know that these are the features of react-create-app, but I'm not sure that I should somehow solve this through overrides
Screenshots
I'm having the same issue, any ideas?
I'm having the same issue, any ideas?
I have my own version of this project in which I fixed all the problems I had. I also added zustand and connected it to the code editor for better interaction. you can try using it if it helps you. https://github.com/xzdwq/swagger-editor
I'm having the same issue, any ideas?
I have my own version of this project in which I fixed all the problems I had. I also added zustand and connected it to the code editor for better interaction. you can try using it if it helps you. https://github.com/xzdwq/swagger-editor
Thank you so much for this!
We’ve released Swagger Editor v5! 🎉 Check out the details here: Inside the New Swagger Editor. We’re closing old issues related to previous versions. If you think any of them are still relevant, please open a new issue – this helps us prioritize what matters most. Thanks for your activity! 🚀