
Product
Introducing Scala and Kotlin Support in Socket
Socket now supports Scala and Kotlin, bringing AI-powered threat detection to JVM projects with easy manifest generation and fast, accurate scans.
gradient-cursor
Advanced tools
A JavaScript library that applies a dynamic and customizable gradient cursor effect to enhance user interaction on web pages.
A JavaScript library that applies a dynamic gradient cursor effect to enhance user interaction on web pages.
12vmax
).You can install gradient-cursor
using your favorite package manager:
# Using pnpm
pnpm add gradient-cursor
# Using npm
npm install gradient-cursor
# Using yarn
yarn add gradient-cursor
Here's how to use the library in your project:
// CommonJS
const applyGradientCursor = require('gradient-cursor');
// ES Modules
import applyGradientCursor from 'gradient-cursor';
applyGradientCursor({ backgroundColor: "#1c2742", gradientColor: "15, 23, 42", gradientSize: "12vmax" });
This will apply a dark blue background with a light gradient cursor with the specified sizer.
https://github.com/user-attachments/assets/bd3692fe-e9fc-4047-a49e-d2e5c1b3363f
applyGradientCursor(options)
Applies the gradient cursor effect with the given options.
options
(object
): Configuration object for the gradient cursor. The options include:
backgroundColor
(string
): [optional] The background color for the body of the page.gradientColor
(string
): [optional] The gradient color for the cursor (in RGB format).gradientSize
(string
): [optional] The size of the cursor (e.g., 12vmax
).void
: This function doesn't return anything, it just applies the cursor effect.If you want to contribute or use the project locally, follow these steps:
git clone https://github.com/laura-benavente/gradient-cursor.git
cd gradient-cursor
npm install
This project uses Jest for testing. To run the test suite, simply use:
npm run test
Example output:
PASS ./index.test.js
✓ should update the cursor position on mouse move
...
Feel free to add more test cases in the test
file.
See CHANGELOG.md for a detailed history of changes.
Contributions are welcome! If you'd like to contribute, please follow these steps:
See CONTRIBUTING.md for more details.
This project is licensed under the MIT License. Created with ❤️ by Laura Benavente.
[1.0.3] - 2025-03-16
FAQs
A JavaScript library that applies a dynamic and customizable gradient cursor effect to enhance user interaction on web pages.
The npm package gradient-cursor receives a total of 0 weekly downloads. As such, gradient-cursor popularity was classified as not popular.
We found that gradient-cursor demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers 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.
Product
Socket now supports Scala and Kotlin, bringing AI-powered threat detection to JVM projects with easy manifest generation and fast, accurate scans.
Application Security
/Security News
Socket CEO Feross Aboukhadijeh and a16z partner Joel de la Garza discuss vibe coding, AI-driven software development, and how the rise of LLMs, despite their risks, still points toward a more secure and innovative future.
Research
/Security News
Threat actors hijacked Toptal’s GitHub org, publishing npm packages with malicious payloads that steal tokens and attempt to wipe victim systems.