
Security News
Axios Maintainer Confirms Social Engineering Attack Behind npm Compromise
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.
shuffle-darkernel
Advanced tools
A simple and efficient array shuffling utility package powered by Lodash
Install the package using npm or pnpm:
npm install shuffle-darkernel
or
pnpm add shuffle-darkernel
The package provides a straightforward way to shuffle arrays using the reliable Lodash shuffle algorithm.
import shuffleArray from 'shuffle-darkernel';
const numbers = [1, 2, 3, 4, 5];
const shuffled = shuffleArray(numbers);
console.log(shuffled); // e.g., [3, 1, 5, 2, 4]
import { shuffleArray } from 'shuffle-darkernel/utils.js';
const colors = ['red', 'blue', 'green', 'yellow'];
const shuffledColors = shuffleArray(colors);
console.log(shuffledColors); // Randomly shuffled array
shuffleArray(array)Shuffles an array using the Fisher-Yates shuffle algorithm (via Lodash).
Parameters:
array (Array): The array to shuffleReturns:
Example:
import shuffleArray from 'shuffle-darkernel';
const deck = ['A', 'K', 'Q', 'J', '10'];
const shuffledDeck = shuffleArray(deck);
console.log(deck); // Original: ['A', 'K', 'Q', 'J', '10']
console.log(shuffledDeck); // Shuffled: ['Q', 'A', '10', 'J', 'K']
# Clone the repository
git clone https://github.com/cggithub333/shuffle-darkernel.git
# Navigate to the project directory
cd shuffle-darkernel
# Install dependencies
pnpm install
# Run the demo
pnpm run dev
Contributions, issues, and feature requests are welcome! Feel free to check the issues page.
This project is ISC licensed.
BrianHa
Made with ❤️ by Darkernel
FAQs
push my shuffle package to npmjs page
We found that shuffle-darkernel 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
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.

Security News
The Axios compromise shows how time-dependent dependency resolution makes exposure harder to detect and contain.