
Security News
OWASP 2025 Top 10 Adds Software Supply Chain Failures, Ranked Top Community Concern
OWASP’s 2025 Top 10 introduces Software Supply Chain Failures as a new category, reflecting rising concern over dependency and build system risks.
A simple stack data structure.
npm install stack-ds -save
Stack() - Constructor var mystack = new Stack();
Stack.isStack(obj) - Check if obj is Stack. Returns boolean. Stack.isStack(myobject);
.push(obj) - Push an obj into the stuck. Returns this. mystack.push({a:5});
.pop() - Pop the top object from the stack. Returns the poped object mystack.pop();
.peek() - Get the top object. var top = mystack.peek();
.size() - Get the size of the stack. var size = mystack.size();
.isEmpty() - Check if the stack is empty. Returns boolean. mystack.isEmpty();
.setMaxSize(max_size) - Set the maximum size of the stack. Returns this. mystack.setMaxtSize(10);
.getMaxSize() - Get the maximum size of the stack. mystack.getMaxtSize();
.empty() - Empty the stack. Returns this. mystack.empty();
.isFull() - Check if the stack is full. Returns boolean. mystack.isEmpty();
.copy(other) - Copies other into this. Returns this. mystack.copy(otherstack);
.compare(other) - Compares other and this stacks. Returns boolean. mystack.compare(otherstack;
.toString(debug) - Export a string representation of the stack. If debug is set to true will export a full representation for each element mystack.toString();
.toArray() - Exports an array with stacks's data. mystack.toArray();
In order to test the library run :
npm test
You need to have mocha installed
npm install -g mocha
MIT
Copyright (c) 2016 Skevos Papamichail <contact@skevosp.me> (www.skevosp.me)
FAQs
A simple stack data structure.
We found that stack-ds 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.

Security News
OWASP’s 2025 Top 10 introduces Software Supply Chain Failures as a new category, reflecting rising concern over dependency and build system risks.

Research
/Security News
Socket researchers discovered nine malicious NuGet packages that use time-delayed payloads to crash applications and corrupt industrial control systems.

Security News
Socket CTO Ahmad Nassri discusses why supply chain attacks now target developer machines and what AI means for the future of enterprise security.