Ver Fonte

Revert incorrect "run" usage in control catalog

Max Katz há 1 ano atrás
pai
commit
c57263e211
1 ficheiros alterados com 3 adições e 2 exclusões
  1. 3 2
      samples/ControlCatalog.Browser/wwwroot/main.js

+ 3 - 2
samples/ControlCatalog.Browser/wwwroot/main.js

@@ -4,8 +4,9 @@ const is_browser = typeof window != "undefined";
 if (!is_browser) throw new Error(`Expected to be running in a browser`);
 
 const dotnetRuntime = await dotnet
-    .withDiagnosticTracing(false)
     .withApplicationArgumentsFromQuery()
     .create();
 
-await dotnet.run();
+const config = dotnetRuntime.getConfig();
+
+await dotnetRuntime.runMain(config.mainAssemblyName, [globalThis.location.href]);