Research
Security News
Malicious npm Package Targets Solana Developers and Hijacks Funds
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
A Node.js JavaScript implementation of the stack data type. Supporting both LIFO via push()
and pop()
, and FIFO via push()
and shift()
.
npm install stack-list
new StackList(initialValue);
initialValue
An Array
of values of any type to initially populate the stack list.
push()
Push a new value to the top of the stack.
pop()
Take the top most value off the list and return it.
shift()
Take the bottom most value off the list and return it.
peek()
View the top most value on the list.
inspect()
View the bottom most value on the list.
clear()
Reset to an empty list.
size
The number of elements in the list. Also available under alias property length
.
const StackList = require('stack-list');
let list = new StackList(['Hey']); // Optional initial values
// Push
list.push('Mate');
// Get size
list.size; // 2
// Peek top value
list.peek(); // 'Mate'
// Pop top value
list.pop(); // 'Mate'
list.pop(); // 'Hey'
// Clear stack
list.clear();
FAQs
A simple stack list data structure.
The npm package stack-list receives a total of 0 weekly downloads. As such, stack-list popularity was classified as not popular.
We found that stack-list demonstrated a not healthy version release cadence and project activity because the last version was released 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.
Research
Security News
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
Security News
Research
Socket researchers have discovered malicious npm packages targeting crypto developers, stealing credentials and wallet data using spyware delivered through typosquats of popular cryptographic libraries.
Security News
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.