6 Answer(s)
-
0
Hi,
See https://github.com/abpio/abp-commercial-docs/pull/120
Open
<YourProjectName>BundleContributor.cs
and replacecontext.Add("main.css");
tocontext.Add("main.css", true);
Open
appsettings.json
and add the following:"AbpCli": { "Bundle": { "Mode": "BundleAndMinify", /* Options: None, Bundle, BundleAndMinify */ "Name": "global", "Parameters": { "LeptonTheme.Style": "Style6", /* Options: Style1, Style2... Style6 */ "LeptonTheme.ChangeStyleDynamically": "true" } } }
Then run
abp bundle
command in theblazor
folder to update resource references. -
0
@liangshiwei Hello, I didn't find the <YourProjectName>BundleContributor.cs file. Can you tell me the exact location?
I created the module through suite, and did not make any changes, just run it directly. And when I run BSDemo.IdentityServer, I need to wait many minutes, which is much slower than running BSDemo.Web.Unified directly. It took 5.1 minutes to display the successful login
By the way, for the module I created, I added a page to BSDemo.Blazor.Server project. How can I run blazor server to view it?
-
0
-
0
@liangshiwei
I am using is the latest 4.3.1 module generated by the version of the suite, in Blazor. Host program and don't have the < YourProjectName > BundleContributor. Cs file.
Did you try again? I don't think it will be so slow
I have try again many times, in different computers are the same.
I am using suite to create module project, how to run Blazor Server?
-
0
Hi,
For module project, try:
public class MyProjectNameBlazorHostBundleContributor : IBundleContributor { public void AddScripts(BundleContext context) { } public void AddStyles(BundleContext context) { context.Add("main.css", true); } }
Open
appsettings.json
and add the following:"AbpCli": { "Bundle": { "Mode": "BundleAndMinify", /* Options: None, Bundle, BundleAndMinify */ "Name": "global", "Parameters": { "LeptonTheme.Style": "Style1", /* Options: Style1, Style2... Style6 */ "LeptonTheme.ChangeStyleDynamically": "true" } } }
Then run
abp bundle
command in theBlazor.Host
folder to update resource references. -
0
This question has been automatically marked as stale because it has not had recent activity.