diff --git a/.gitignore b/.gitignore
index b3d95c0..c68b731 100644
--- a/.gitignore
+++ b/.gitignore
@@ -8,3 +8,4 @@ out/
splashkit/
generated/
__pycache__/
+_framework/
\ No newline at end of file
diff --git a/Browser_IDE/CSharpWasm/bin/CSharpWasm.dll b/Browser_IDE/CSharpWasm/bin/CSharpWasm.dll
new file mode 100644
index 0000000..3c0fa1d
Binary files /dev/null and b/Browser_IDE/CSharpWasm/bin/CSharpWasm.dll differ
diff --git a/Browser_IDE/CSharpWasm/bin/System.Console.dll b/Browser_IDE/CSharpWasm/bin/System.Console.dll
new file mode 100755
index 0000000..486ae0f
Binary files /dev/null and b/Browser_IDE/CSharpWasm/bin/System.Console.dll differ
diff --git a/Browser_IDE/CSharpWasm/bin/System.Private.CoreLib.dll b/Browser_IDE/CSharpWasm/bin/System.Private.CoreLib.dll
new file mode 100755
index 0000000..ffa92d2
Binary files /dev/null and b/Browser_IDE/CSharpWasm/bin/System.Private.CoreLib.dll differ
diff --git a/Browser_IDE/CSharpWasm/bin/System.Runtime.dll b/Browser_IDE/CSharpWasm/bin/System.Runtime.dll
new file mode 100755
index 0000000..0e2db79
Binary files /dev/null and b/Browser_IDE/CSharpWasm/bin/System.Runtime.dll differ
diff --git a/Browser_IDE/CSharpWasm/bin/mscorlib.dll b/Browser_IDE/CSharpWasm/bin/mscorlib.dll
new file mode 100755
index 0000000..f79abde
Binary files /dev/null and b/Browser_IDE/CSharpWasm/bin/mscorlib.dll differ
diff --git a/Browser_IDE/CSharpWasm/bin/netstandard.dll b/Browser_IDE/CSharpWasm/bin/netstandard.dll
new file mode 100755
index 0000000..fd34bf9
Binary files /dev/null and b/Browser_IDE/CSharpWasm/bin/netstandard.dll differ
diff --git a/Browser_IDE/CSharpWasm/main.js b/Browser_IDE/CSharpWasm/main.js
new file mode 100644
index 0000000..65ad257
--- /dev/null
+++ b/Browser_IDE/CSharpWasm/main.js
@@ -0,0 +1,58 @@
+import { dotnet } from "./wwwroot/_framework/dotnet.js";
+
+const loadDotNet = async () => {
+ const { setModuleImports, getAssemblyExports, getConfig } = await dotnet
+ .withDiagnosticTracing(false)
+ .withApplicationArgumentsFromQuery()
+ .create();
+
+ setModuleImports("main.js", {
+ window: {
+ location: {
+ href: () => globalThis.window.location.href,
+ },
+ },
+ SplashKitBackendWASM: {
+ // TODO: Pass the rest of the SplashKit functions
+ write_line,
+ refresh_screen,
+ open_window,
+ fill_ellipse: () => {
+ // Research how to pass a JS object in WASM
+ fill_ellipse(color_black(), 260, 260, 200, 200);
+ },
+ },
+ });
+
+ const config = getConfig();
+ const exports = await getAssemblyExports(config.mainAssemblyName);
+ return exports;
+};
+
+const CompileAndRun = async (code, reportError) => {
+ try {
+ const exports = await loadDotNet();
+ const result = await exports.CSharpCodeRunner.CompileAndRun(code);
+ if (result.includes("Compilation failed")) {
+ const errors = result.split(":");
+ const errorLine = errors[1].split("Line");
+
+ const indexCorrector = 1;
+ const filePath = "__USERCODE__/code/main.cs";
+ reportError(
+ filePath,
+ result,
+ Number(errorLine[1]) + indexCorrector,
+ null,
+ true,
+ );
+ }
+ } catch (error) {
+ console.error("Error during code execution:", error);
+ }
+};
+
+// This event will be trigger by the csharp compiler
+document.addEventListener("compileAndRun", (ev) => {
+ CompileAndRun(ev.detail.program[0].source, ev.detail.reportError);
+});
diff --git a/Browser_IDE/compilers/csharp/csharpCompiler.js b/Browser_IDE/compilers/csharp/csharpCompiler.js
new file mode 100644
index 0000000..b6869f9
--- /dev/null
+++ b/Browser_IDE/compilers/csharp/csharpCompiler.js
@@ -0,0 +1,33 @@
+"use strict";
+
+class CSharpCompiler extends Compiler {
+ constructor() {
+ super();
+ this.signalReady();
+ }
+
+ async compileAll(compileList, sourceList, print) {
+ let compiled = {
+ output: null,
+ };
+
+ let hasErrors = false;
+
+ // If all good, then output the 'compiled' result
+ if (!hasErrors) {
+ compiled.output = [];
+ for (let i = 0; i < sourceList.length; i++) {
+ compiled.output.push({
+ name: sourceList[i].name,
+ source: sourceList[i].source,
+ });
+ }
+ }
+
+ return compiled;
+ }
+
+}
+
+// The name has to match the one in languageDefinitions.js
+registerCompiler("csharpCompiler", new CSharpCompiler());
diff --git a/Browser_IDE/executionEnvironment.html b/Browser_IDE/executionEnvironment.html
index 6830dd5..842da29 100644
--- a/Browser_IDE/executionEnvironment.html
+++ b/Browser_IDE/executionEnvironment.html
@@ -41,5 +41,4 @@
-