
Security News
Attackers Are Hunting High-Impact Node.js Maintainers in a Coordinated Social Engineering Campaign
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.
data-transport
Advanced tools
A simple and responsive transport
Many front-end communication APIs based on JavaScript are almost one-way communication, and their communication interface are often different. In terms of communication interaction protocols, we need an universal and responsive communication library that will help us communicate in any scenario very simply and easily.
And It is also very easy to mock to be used for testing, and it is also easy to design an common interface that is compatible with multiple communication APIs.
You can use data-transport to communicate between different front-end communication APIs.
data-transport is a generic and responsive communication transporter
yarn add data-transport
import { createTransport } from 'data-transport';
const external = createTransport('IFrameMain');
external.listen('hello', async (num) => ({ text: `hello ${num}` }));
import { createTransport } from 'data-transport'
const internal = createTransport('IFrameInternal');
expect(await internal.emit('hello', 42).toEqual({ text: 'hello 42' });
createTransport()
Create a transport instance by transport options.
mockPorts()
Mock ports for testing.
merge()
Merge multiple transports into one transport.
TransportMessageTransportIFrameMainTransportIFrameInternalTransportSharedWorkerClientTransportSharedWorkerInternalTransportServiceWorkerClientTransportServiceWorkerServiceTransportWorkerMainTransportWorkerInternalTransportBrowserExtensionsGenericTransportBrowserExtensionsMainTransportBrowserExtensionsClientTransportElectronMainTransportElectronRendererTransportWebRTCTransportBroadcastTransportMainProcessTransportChildProcessTransportFAQs
A simple and responsive transport
We found that data-transport demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

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.

Security News
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.

Security News
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.

Security News
Node.js has paused its bug bounty program after funding ended, removing payouts for vulnerability reports but keeping its security process unchanged.