Uncaught SyntaxError: Unexpected token '<' (at swagger-ui-bundle.js:1:1)
See original GitHub issueIs there an existing issue for this?
- I have searched the existing issues
Current behavior
Hi
I use @nestjs/swagger^6.0.4, and when I want to see the swagger’s page, I got this errors
Uncaught SyntaxError: Unexpected token '<' (at swagger-ui-bundle.js:1:1) Uncaught SyntaxError: Unexpected token '<' (at swagger-ui-standalone-preset.js:1:1) Uncaught ReferenceError: SwaggerUIBundle is not defined at window.onload (swagger-ui-init.js:210:7)
I don’t know why, it works until two days ago, and I didn’t change anything in my code.
Minimum reproduction code
https://github.com/smartmakran/backend
Steps to reproduce
No response
Expected behavior
show the swagger’s page
Package version
6.0.4
NestJS version
8.2.1
Node.js version
16.13.1
In which operating systems have you tested?
- macOS
- Windows
- Linux
Other
No response
Issue Analytics
- State:
- Created a year ago
- Comments:6 (3 by maintainers)
Top Results From Across the Web
Uncaught SyntaxError: Unexpected token ... - GitHub
After installing on server got: Uncaught SyntaxError: Unexpected token '<' Uncaught ReferenceError: SwaggerUIBundle is not defined at ...
Read more >Swagger UI not fetching resources (Uncaught SyntaxError
On Chrome, UI stops in "fetching resource list" message, and this error in developers console: "Uncaught SyntaxError: Unexpected token". Network tab:.
Read more >Uncaught SyntaxError: Unexpected token : - Stack Overflow
I was getting: Uncaught SyntaxError: Unexpected token < and the error was pointing to this line in my ajax success statement: var total...
Read more >SyntaxError: Unexpected token < in JSON at position 0
Im trying to get a single object from the api, it worked fine for other pages but for some reason it doesnt work...
Read more >MDVA-44887: 'Uncaught SyntaxError: Unexpected token ...
The *Uncaught SyntaxError: Unexpected token const* error is displayed in the Admin panel. This patch is available when the [Quality Patches ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I had a stupid mistake, it’s ok right now. thanks.
I had a mistake in my route name