Tsonic.Nodejs 1.0.2

dotnet add package Tsonic.Nodejs --version 1.0.2
                    
NuGet\Install-Package Tsonic.Nodejs -Version 1.0.2
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Tsonic.Nodejs" Version="1.0.2" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Tsonic.Nodejs" Version="1.0.2" />
                    
Directory.Packages.props
<PackageReference Include="Tsonic.Nodejs" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Tsonic.Nodejs --version 1.0.2
                    
#r "nuget: Tsonic.Nodejs, 1.0.2"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Tsonic.Nodejs@1.0.2
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Tsonic.Nodejs&version=1.0.2
                    
Install as a Cake Addin
#tool nuget:?package=Tsonic.Nodejs&version=1.0.2
                    
Install as a Cake Tool

nodejs-clr

nodejs-clr is a .NET library that provides Node-style APIs (filesystem, path, crypto, networking, etc.) for Tsonic projects.

It is Node-inspired (familiar ergonomics), but it is not Node.js itself and it is not an exact replica of the Node standard library.

For Tsonic Users

Install and enable the bindings package:

# new project
tsonic init
tsonic add npm @tsonic/nodejs

# existing project
tsonic add npm @tsonic/nodejs

Then import Node-style modules from @tsonic/nodejs/index.js:

import { console, fs, path } from "@tsonic/nodejs/index.js";

export function main(): void {
  console.log(path.join("a", "b", "c"));
  console.log(fs.readFileSync("./README.md", "utf-8"));
}

Some namespaces are emitted as separate ESM entry points (for example nodejs.Http) and are imported via a subpath:

import { http } from "@tsonic/nodejs/nodejs.Http.js";

Documentation:

For Contributors

Build:

dotnet build

If dotnet build fails with "Build FAILED" but no errors (some sandboxed environments block MSBuild node sockets), try:

dotnet build -- -maxcpucount:1

Test:

dotnet test

The @tsonic/nodejs package is generated from the compiled assembly via tsbindgen.

License

MIT

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.0.2 82 2/23/2026
1.0.1 88 2/15/2026
1.0.0 96 2/13/2026