shadergradient
Integrates ShaderGradient moving 3D gradients in React/Next.js apps with safe defaults and performance-aware setup. Use when users mention shadergradient, animated gradients, GLSL backgrounds, @shadergradient/react, or gradient hero backgrounds.
How do I install this agent skill?
npx skills add https://github.com/masermediagroup-stack/cursorskills --skill shadergradientIs this agent skill safe to install?
- Gen Agent Trust Hubpass
This skill provides instructions and code examples for integrating the ShaderGradient library into React and Next.js applications. It utilizes official NPM packages and standard integration patterns. No security risks or malicious behaviors were identified during the analysis.
- Socketpass
No alerts
- Snykpass
Risk: LOW · No issues
What does this agent skill do?
ShaderGradient Integration
Use this skill to add high-quality animated gradient backgrounds with @shadergradient/react.
When To Use
- User asks for ShaderGradient integration in React or Next.js
- User wants animated gradient hero/background sections
- User mentions
@shadergradient/reactorshadergradient.cosettings URLs - User needs tuneable color/animation gradients with Three.js
Install
Install required runtime packages:
npm i @shadergradient/react @react-three/fiber three three-stdlib camera-controls
npm i -D @types/three
Baseline Usage
Use ShaderGradient inside ShaderGradientCanvas.
import { ShaderGradient, ShaderGradientCanvas } from "@shadergradient/react";
export function GradientBackground() {
return (
<ShaderGradientCanvas style={{ position: "absolute", inset: 0 }} pixelDensity={1.5} fov={45}>
<ShaderGradient cDistance={3.2} cPolarAngle={125} animate="on" />
</ShaderGradientCanvas>
);
}
Next.js Guidance
- Prefer a client component wrapper (
"use client") for gradient components - Mount as a visual background layer, then keep content in a positioned foreground container
- Keep
pixelDensityconservative (for example1to1.5) on heavy pages - Avoid multiple full-screen gradient canvases on the same route
Preset From URL
If user gives a settings URL, load it directly:
<ShaderGradientCanvas>
<ShaderGradient control="query" urlString="https://www.shadergradient.co/customize?...your-settings..." />
</ShaderGradientCanvas>
Performance Checklist
- Start with
animate="off"when debugging layout, enable after placement is correct - Reduce
uStrength,uFrequency, andpixelDensityfor lower-end devices - Keep gradient isolated from expensive re-render trees
- Check for reduced motion preferences before enabling aggressive animation
Common Defaults
type:planelightType:3danimate:oncDistance:3to4cPolarAngle:90to125pixelDensity:1to1.5
Extra Reference
- For property details and patterns, see reference.md
How can the creator link this skill?
Add the canonical catalog link to the repository README so users can inspect current installs and available audits. The publishing guide covers the complete discovery path.
<a href="https://skillzs.dev/skills/masermediagroup-stack/cursorskills/shadergradient">View shadergradient on skillZs</a>