Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Microsoft.JSInterop.JSException: 'Could not find 'BlazoredModal' in 'window'. [Bug]

See original GitHub issue

Describe the bug A clear and concise description of what the bug is. I’m pretty new with the webpack.config, but it seems not injecting blazored.modal.js as it should do…

To Reproduce Steps to reproduce the behavior: 1- Started the Samples/BlazorServer project 2- Client the Show Modal button on the index page… 3- Get error: Microsoft.JSInterop.JSException: 'Could not find ‘BlazoredModal’ in ‘window’.

Expected behavior A clear and concise description of what you expected to happen. It seems that the BlazoredModal.activateScrollLock function is never injected in the _Host.cshtml page in the <script src="_content/Blazored.Modal/blazored.modal.js"></script> tag.

Screenshots If applicable, add screenshots to help explain your problem.

Hosting Model (is this issue happening with a certain hosting model?):

  • Blazor Server

Additional context Add any other context about the problem here.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:23 (7 by maintainers)

github_iconTop GitHub Comments

chrissaintycommented, Jul 18, 2020

@frablaser .NET 5 won’t have any impact on this library and while I appreciate your concern that a library could become unmaintained, it seems your actions are a bit counter-intuitive. If you’d just used the NuGet package you would have saved yourself a day at least. You could always resort to the source code in the future if the library became stagnant.

As this isn’t an issue with the production code we ship and just a local setup issue I’m going to close this issue. Happy to keep helping you with local setup if that’s the route you want to take but there isn’t any work for us to do here.

chrissaintycommented, Jul 18, 2020

Is there a reason why you are not using the Nuget package? The Nuget package just uses the javascript file which gets compiled from the *.ts file.

@larsk2009 you beat me to it 😉

Read more comments on GitHub >

github_iconTop Results From Across the Web

Blazored Modal won't show up
I updated Blazored.Modal a few days ago but now my PopUp won't work. I adjusted the code but it still won't work and...
Read more >
Getting error of JS function call - Microsoft Q&A
I am getting error while loading, I created the js function and call into razor component on load it will throw error as...
Read more >
Microsoft.JSInterop.JsException: could not find 'C1 in 'window
Hi, The error is because of the missing JS and CSS references from the project. Please refer to the attached projects' wwwroot/index.html ...
Read more >
JavaScript Errors - Telerik UI for Blazor - Documentation
Microsoft.JSInterop.JSException: Could not find 'TelerikBlazor' in 'window'. If you get such errors, the reason may be: The telerik-blazor.js JS Interop ...
Read more >
Could not find 'createScheduler' in 'window.Radzen'
Hello. I am trying to create page with RadzenScheduler like manual's example, but when i'm trying to do this i get error from...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Post

No results found

github_iconTop Related Hashnode Post

No results found