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

better-abstractsocket

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

better-abstractsocket

A Node.js module for abstract Unix domain sockets on Linux and macOS.

latest
Source
npmnpm
Version
1.0.2
Version published
Maintainers
1
Created
Source

better-abstractsocket

English | 简体中文

better-abstractsocket is a Node.js module designed to create and manipulate abstract Unix domain sockets. It only supports Linux and macOS systems. This module encapsulates low - level socket operations, providing developers with a more convenient interface to create and manage abstract sockets.

Features

  • Platform Support: Only supports Linux and macOS systems.
  • Core Functions: Provides functions to create sockets (socket), bind addresses (bind), connect to sockets (connect), and close sockets (close).

Installation

pnpm install better-abstractsocket

Usage Examples

Create a Server

import AbstractSocket from 'better-abstractsocket';

const server = new AbstractSocket.Server();
server.listen('better-abstractsocket-example', () => {
    console.log('Server is listening on better-abstractsocket-example');
});

Create a Connection

import { createConnection } from 'better-abstractsocket';

const socket = createConnection('better-abstractsocket-example', () => {
    console.log('Connected to abstract socket');
});

API Documentation

AbstractSocket.Server

Inherits from net.Server and provides the listen method to listen on an abstract socket.

createConnection

Used to create a connection to a specified abstract socket.

supported

A boolean value indicating whether the current environment supports the better-abstractsocket module.

Keywords

abstract-socket

FAQs

Package last updated on 03 Jul 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