-
Notifications
You must be signed in to change notification settings - Fork 518
JavaScript runtime error: 'Promise' is undefined #575
Comments
Hi Jon, You may be using a browser that doesn't support Promises. You could try running in a different browser (latest Chrome works for me) or add the babel-polyfill : https://babeljs.io/docs/usage/polyfill/. Chris |
Hi Chris, and thanks for responding! Sorry for not mentioning it, but I'm actually using the latest version of Chrome. Another thing I realize I probably should mention, is that it's the Visual Studio debugger that breaks and displays the error. I haven't noticed any errors in the browsers console logs. Jon |
Are you sure you're really using Chrome or Edge with the Visual Studio debugger? Neither of them are supported by the VS debugger out of the box - it only works directly with Internet Explorer. How have you set up the VS debugger to work with Chrome or Edge? It seems likely to me that the issue is as @chris-herring describes, which is that the VS debugger is connecting to IE11, and that doesn't contain Promise support without a polyfill. If that is the case, it's certainly a legitimate issue, though it's already being tracked as #484. Can we close this in favour of #484, or can you confirm exactly how we can repro the issue working with Chrome? As in, what steps should we take to configure VS's debugger to work with it? |
You're absolutely right - my apologies! My current dev. environment is quite new to me (I've been running win8 with IE and Chrome until I started this project), and realize now that the VS debugger is spinning up IE11 and not Edge. Closing this issue! Regards, |
When generating a solution running "yo aspnetcore-spa" and choosing:
...a new application is generated for me.
I can start the application with "dotnet run", and all is good.
But when I open the solution in VS2015 and start the app in debug mode (F5), I get an error saying
Unhandled exception at line 695, column 3 in http://localhost:38523/dist/app.js
and
JavaScript runtime error: 'Promise' is undefined
I can click Continue and open the website as if nothing happened, but I'd really like to make that error go away for my own peace of mind.
Am I doing something wrong, or is it a bug in the template-files (if that's what their called)..?
Regards,
Jon S.
The text was updated successfully, but these errors were encountered: