Skip to content

asynkron/Asynkron.JsEngine

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Asynkron.JsEngine

A lightweight JavaScript interpreter written in C# that parses and evaluates JavaScript code using an S-expression intermediate representation.

📚 Documentation

All documentation is organized in the docs/ folder. This is the main entry point for all documentation.

Getting Started

Feature Documentation

Architecture & Design

Implementation Details

Investigations & Debugging

  • Investigations - Investigation notes and debugging documentation
  • Key investigations: Parser vs CPS analysis, promise rejection investigation, exception channel results

Status & Planning


Quick Overview

Asynkron.JsEngine targets ECMAScript 262 with full language coverage and a steadily growing built-in library.

Current Status

  • ECMAScript 262 language: 100% compliant; all language-focused Test262 cases pass.
  • Built-ins / standard library: ~50% compliant; about half of the ES built-ins are implemented on the attribute-driven generator model and the rest are being migrated. See docs/FEATURE_STATUS_SUMMARY.md for the latest coverage.

Capabilities

  • Variables, functions, classes, objects, arrays
  • Async/await, Promises, generators
  • ES modules (import/export) including dynamic imports
  • Template literals, destructuring, spread/rest, operators, and control flow
  • Implemented built-ins include Object, Array/TypedArray/ArrayBuffer/SharedArrayBuffer/DataView, Promise, Math, Date, JSON, RegExp, Reflect, Console, Symbol, Map/Set/WeakMap/WeakSet, BigInt, and async iteration helpers. Standard library coverage is expanding as more types move onto the generated constructor/prototype surface.

See Complete Feature List for detailed documentation with examples.


Running the Demo

Console application demos are included in the examples folder:

Main Demo

cd examples/Demo
dotnet run

The main demo showcases basic features including variables, functions, closures, objects, arrays, control flow, operators, and standard library usage.

Promise and Timer Demo

cd examples/PromiseDemo
dotnet run

Demonstrates setTimeout, setInterval, Promise creation, chaining, error handling, and event queue processing.

NPM Package Compatibility Demo

cd examples/NpmPackageDemo
dotnet run

Shows that the engine can run pure JavaScript npm packages without Node.js dependencies.

S-Expression Demo

cd examples/SExpressionDemo
dotnet run

Displays the S-expression representation and CPS transformation of JavaScript code. See Transformation Pipeline for details.


Building and Testing

# Build the solution
dotnet build

# Run tests
cd tests/Asynkron.JsEngine.Tests
dotnet test

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

License

See LICENSE file for details.

Credits

Developed by Asynkron

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 3

  •  
  •  
  •  

Languages