Blazor | DevExpress UI for Blazor | Grid library
kandi X-RAY | Blazor Summary
kandi X-RAY | Blazor Summary
DevExpress UI for Blazor ships with native and high performance UI components including the Data Grid, Pivot Grid, Scheduler, Charts, and Data Editors. These components can help you create intuitive and refined user experiences for Blazor Server (ASP.NET Core) and Blazor WebAssembly hosting models.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of Blazor
Blazor Key Features
Blazor Examples and Code Snippets
Community Discussions
Trending Discussions on Blazor
QUESTION
If I create a new Blazor WASM app, out of the box I can use Hot Reload by running dotnet watch run
in a terminal window. This will launch a browser window, and any changes I make will update in the browser automatically.
However, if I start my app in Visual Studio with the debugger attached (F5), I don't get any hot reload functionality. When I make a change, Visual Studio shows a message in the bottom left that says Code Changes were applied successfully
, but the browser does not refresh. If I refresh the browser manually, I still do not see my changes.
I have "Hot Reload on Save" checked. Pressing the new Hot Reload button doesn't seem to do anything.
The browser refresh script is injected into my html.
I am using Visual Studio 2022 Version 17.0.0 Preview 7.0, and dotnet 6 RC 2 (6.0.0-rc.2.21480.10).
Is it not possible to use Hot Reload while debugging a Blazor WASM app, or am I missing something?
...ANSWER
Answered 2022-Mar-02 at 17:39This bug has been fixed as of version 17.1 of Visual Studio 2022.
PosterityThis feature is currently unsupported when using the debugger in WebAssembly apps. According to Microsoft:
*In Visual Studio 2022 GA release Hot Reload support for Blazor WebAssembly when using the Visual Studio debugger isn’t enabled yet. You can still get Hot Reload If you start your app through Visual Studio without the debugger, and we are working to resolve this in the next Visual Studio update.
According to Microsoft, this will be fixed in the 17.1 release of VS 2022.
The fix will be included in the 17.1 release.
The latest preview version of Visual Studio 2022 (17.1.0 Preview 2 released Jan 5, 2022) contains the fix for this. I tested this personally and verified it's working. Note that you will still need to wait for 17.1 if you don't want to use the preview channel.
QUESTION
I'm getting "; expected" error in my .razor
file and in _razor.g.cs
file,
In previous blazor versions I was finding these g.cs
files in the solution folder, now I can't find them there, and double clicking on the error message in VS doesn't point me to anywhere (error message has no line number, the one for .g.cs has a line number), and I can't find the problem.
Where are the _razor.g.cs files located now ?
...ANSWER
Answered 2022-Feb-18 at 19:41Edit the project file (.csproj) and add this:
QUESTION
I am using Mudblazor in my Blazor app. I have the following code in a component inside ValidSubmit handler:
...ANSWER
Answered 2021-Aug-17 at 11:10Show
returns a reference to the opened dialog!
So all you need to do is this:
QUESTION
After using VS 2022 preview for several iterations I removed it and installed VS 2022 Current when it became available.
Existing Blazor hosted application does not Hot reload on file save or on pressing Hot reload button. It was reloading "fine" in preview versions. It does not matter if I run it with or without debugging.
New application created with newly installed version does Hot reload.
I don't see any important difference in *.csproj or launchSettings.json files. They both target net6.0. I also removed .vs directory and cleaned solution.
Only difference there is is that my projects are using Program.cs and Startup.cs vs only Program.cs in new application template, but that does not matter. Or, does it?
What is preventing Visual Studio from Hot reloading existing application?
UPDATE
Switching to single Program.cs and WebApplication builder did help somewhat. Now hot reload works without debugging. With debugging VS says it applied changes but they are not applied on screen.
Still I would like to know why is this change necessary and how to enable Hot reload while debugging?
...ANSWER
Answered 2021-Nov-23 at 21:55For your issue, currently Blazor WebAssembly only supports hot reload when not debugging. This is kind of documented here: https://docs.microsoft.com/en-us/aspnet/core/test/hot-reload?view=aspnetcore-6.0
In Visual Studio 2022 GA (17.0), Hot Reload is only supported when running without the debugger.
I found your Q while trying to diagnose why my own existing Blazor WebAssembly ASP.Net Core hosted app wouldn't hot reload and after 4-5 hours of trying all sorts of things I finally found that there was a project reference to a class library that still targeted .NET 5. In my case this reference was no longer required, removing it fixed my issues and my Hot Reload output once again showed.
QUESTION
I have to decompress some gzip text in .NET 6 app, however, on a string that is 20,627 characters long, it only decompresses about 1/3 of it. The code I am using code works for this string in .NET 5 or .NETCore 3.1 As well as smaller compressed strings.
...ANSWER
Answered 2022-Feb-01 at 10:43Just confirmed that the article linked in the comments below the question contains a valid clue on the issue.
Corrected code would be:
QUESTION
I want to be able to call C# code from JavaScript. The mono project used to have a WASM SDK that you could download from their old Jenkins server, but that is no longer public. Existing docs tend to point toward those builds. The Azure Devops builds do not include this SDK. A few messages I've seen on their Github account indicate that they are now focusing on the .NET 6 for WASM. I do not wish to use the Blazor components. Is there a way in .NET 6 to build a minimally sized WASM binary without the Blazor UI?
...ANSWER
Answered 2021-Aug-26 at 01:25Yes it's absolutely possible. Blazor does not have a monopoly on C#/WASM and it's far from clear that it's going to wind up being the best long term option (and a lot of evidence it's not).
I recommend starting with the Uno WASM Bootstrap. https://github.com/unoplatform/Uno.Wasm.Bootstrap
QUESTION
I have a Razor Class Library that I've been using for months with .NetCore3 then .NetCore 5 without a problem.
After recently updating our blazor server application and our Razor Class Library to .NetCore 6 I've hit a problem loading the assets from the Razor Class Library.
The RCL is built and packaged via nuget and I can see the assets in the package, for example;
The web application has been updated to use a single program.cs and I'm using WebApplication.CreateBuilder()
with options for my setup.
ANSWER
Answered 2021-Nov-29 at 14:51So my problem was with the way Azure was building the RCL solution and packaging the RCL in a nuget package.
I had to update my build YML to use 2022 image, and v6.0 of .NET and nuget:
Changed
QUESTION
I would like to implement light and dark theme inside of my Maui Blazor application. As you know, Blazor is nothing other than Html and Css so I easily implement dark and light theme for the content of my app (thanks to a simple .dark class added on the html tag).
The problem I am facing is for the upper and lower part of the Maui application.
Let me show you by an example.
Android version
iOS version
The pictures above show you the current situation: on the left, the light theme and on the right, the dark theme. As you can see, the dark theme is problematic for the top and bottom sections (only the top section is problematic for the iOS version).
What I would like to achieve: the top and bottom sections should be colored the same as the content of the page:
- #292929 for the Dark theme
- #FFFFFF for the Light theme
Something like the picture below: when switching to the dark theme, everything is coloured.
I have no idea how to achieve this for Maui Blazor and I have no experience with Xamarin.
Can you point me to the right direction please ?
As you probably know, BlazorWebView enables you to host a Blazor web application right in the .NET MAUI application.
...ANSWER
Answered 2021-Dec-10 at 03:23Within the next month or two, it should become possible to do this via StatusBarEffect
and NavigationBarEffect
in MAUI Community Toolkit. Discussion here - for Xamarin Toolkit.
Those effects are currently in branch xamarin.develop
of Xamarin.Community.Toolkit
. The change will also get merged to Maui Toolkit, not sure when exactly.
Below is based on that source code, adapted to work with MAUI. Tested.
Android:
QUESTION
I have a Blazor client/server app that I have been working on for a period and it has been working fine up to now. I suddenly started getting this error
Failed to find a valid digest in the 'integrity' attribute for resource 'https://mydomain.no/_framework/Faso.Blazor.SpinKit.dll' with computed SHA-256 integrity '1UEuhA1KzEN0bQcoU0m1eL4WKcCIWHhPgoXydAJnO9w='. The resource has been blocked.
Failed to find a valid digest in the 'integrity' attribute for resource
I have tried to clean and rebuild. I have tried to add Cors, set folder permission, and many other suggested solutions, but to no avail. I am using web deploy in VS 2022 and Win Server 2016, .net core 5.0.
Any suggestions would be appreciated.
...ANSWER
Answered 2021-Nov-11 at 21:27This is an annoying issue indeed and I'm getting that error every now and then. It seems to happen after updating some packages, and the build processes fails to pick up the new SHA for the package.
You can verify that this is the issue by finding the file containing the SHAs and compare the SHA for the dll in question with the SHA from the error message.
This file is called blazor.boot.json
and is generated deep inside the obj
-folder of your project folder.
(mine was here: obj\Release\net6.0\win-x86\PubTmp\Out\wwwroot\_framework
)
If was the issue, please try this:
- Close VS.
- Delete the
obj
andbin
folders from all your projects. (the web project might be enough, but hey - can't hurt) - Start VS
- Rebuild solution.
- Try Publish again.
QUESTION
I updated my Asp.net core Blazor WebAssembly app to .net 6. Everything is fine, but the deploy from github actions doesn't work and throws this error:
...ANSWER
Answered 2021-Nov-15 at 05:26On Linux, it's important that any bash deployment scripts that get run have Unix line endings (LF) and not Windows line endings (CRLF).
Kuduscript will generate scripts with platform-appropriate line endings, but if those scripts are modified, or if you provide your own custom deployment scripts, it's important to make sure that your editor doesn't change the line endings.
If something seems off with your deployment script, you can always use the Kudu console to delete the contents of /home/site/deployments/tools.
This is the directory where Kudu caches kuduscript-generated deployment scripts. On the next deployment, the script will be regenerated.
The error you're currently seeing is a Kudu issue with running node/npm for deployments.
The easiest and fastest resolution for what you are currently seeing is to specify engines.node in your package.json.
Error: EISDIR: illegal operation on a directory, open '/home/site/wwwroot/wwwroot/Identity/lib/bootstrap/LICENSE'
EISDIR stands for "Error, Is Directory". This means that NPM is trying to do something to a file but it is a directory. In your case, NPM is trying to "read" a file which is a directory. Since the operation cannot be done the error is thrown.
Three things to make sure here
- Make sure the file exists. If it does not, you need to create it. (If NPM depends on any specific information in the file, you will need to have that information there).
- Make sure it is in fact a file and not a directory.
- It has the right permissions. You can change the file to have all permissions with "sudo chmod 777 FILE_NAME".
Note: You are giving Read, Write and Execute permissions to every one on that file.
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install Blazor
Prerequisites
Create an Application
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page