New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

node-golang

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

node-golang

Use Go code inside Node.js

latest
npmnpm
Version
1.0.0
Version published
Maintainers
1
Created
Source

node-golang

Use Go code inside Node.js.

Installation

npm install node-golang

or with Yarn:

yarn add node-golang

Usage

ESM

import { golang } from "node-golang";

const fmt = await golang.import("fmt");
fmt.Println("Hello world");

const myModule = await golang.import("github.com/user/package");
myModule.YourFunc();

CJS

const { golang } = require("node-golang");

golang.import("fmt").then(fmt => {
  fmt.Println("Hello world");
});

golang.import("github.com/user/package").then(mod => {
  mod.YourFunc();
});

Keywords

go

FAQs

Package last updated on 02 Dec 2025

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts