Setting up source code for Avalonia port.
This commit is contained in:
parent
27e6c97712
commit
8110fe420e
53 changed files with 991 additions and 58 deletions
13
src/AdvancedCalculator.Browser/wwwroot/main.js
Normal file
13
src/AdvancedCalculator.Browser/wwwroot/main.js
Normal file
|
@ -0,0 +1,13 @@
|
|||
import { dotnet } from './_framework/dotnet.js'
|
||||
|
||||
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();
|
||||
|
||||
const config = dotnetRuntime.getConfig();
|
||||
|
||||
await dotnetRuntime.runMain(config.mainAssemblyName, [globalThis.location.href]);
|
Loading…
Add table
Add a link
Reference in a new issue