shaders README

The project's README from github.com/shader-effects-inc/shaders. As one markdown file: README.md.

Shaders

Design WebGPU effects with your AI agent,
then ship them as components in your web projects

npm version npm downloads per month jsDelivr hits (npm) NPM License

Shaders

Shaders is a desktop app for designing interactive effects with your coding agent. You ask Claude Code, Cursor, Codex or any other MCP agent for what you want, watch it build on an infinite canvas, and adjust it by hand. When it looks right, your agent installs it in your project as ordinary component code.

That code runs on the engine in this repository: a WebGPU renderer and 200+ components (gradients, noise, glass, metal, light, distortions, transitions, blurs, cursor effects) that you nest, blend and mask like any other component. The engine and components are MIT licensed and published as the shaders npm package. You can use them without the app, and everything the app makes runs on them.

npm install shaders

Contents

  1. Design with your agent
  2. Use the components directly
  3. The CLI
  4. Writing Shaders code with an agent
  5. Build your own component
  6. Free and Pro
  7. License
  8. Contribute

Design with your agent

Download Shaders for macOS, Windows or Linux and create an account. Then connect your agent:

npx shaders mcp

The command finds the agents on your machine and adds the Shaders MCP server to each one. Sign in with the same account as the app when your agent asks. Keep the app open while your agent works, since it builds in the editor you have open.

Then tell it what you're designing, for example "Design three shader ideas for my hero background." Each idea gets its own frame on the canvas, so you can compare them side by side. Click any shader to see its layers and change colors, speed and other settings yourself, or ask your agent for changes in plain words. If the shader is for a specific place, like a hero or a pricing card, your agent can draw the page around it so you see it in context.

If nothing in the library fits, your agent can write a new component and give it props you can adjust in the editor. It can also add entrance, exit, hover and scroll animations.

Once a shader is ready, ask your agent to install it. It writes the shader as a component for your framework and adds it to your page, where you and your agent can keep editing it like the rest of your code.

Getting started · Working with your agent

Use the components directly

<Shader> renders the canvas. Its children are layers, drawn top to bottom and blended on the GPU.

import { Shader, LinearGradient, CursorTrail } from 'shaders/react'

<Shader className="w-full h-64">
  <LinearGradient colorA="#0f172a" colorB="#7c3aed" />
  <CursorTrail />
</Shader>

The same components and props work everywhere. Import them from shaders/react, shaders/vue, shaders/svelte or shaders/solid, which also covers projects built on those, like Next.js, Nuxt, Astro and Framer. Without a framework, use createShader from shaders/js:

import { createShader } from 'shaders/js'

await createShader(document.getElementById('my-shader'), {
  components: [
    { type: 'LinearGradient', props: { colorA: '#0f172a', colorB: '#7c3aed' } },
    { type: 'CursorTrail' },
  ],
})

Everything is typed, props update reactively, and the components are safe to server render. Visitors need a browser with WebGPU; without it the canvas stays transparent and the rest of the page works as normal.

Quickstart · All 200+ components, each with a live preview and every prop documented

The CLI

The CLI links a codebase to your Shaders account, so the shaders you design land in your project as component files and stay in sync. It runs through npx, so there's nothing to install globally, and your agent can run it for you.

npx shaders                # guided menu: shows what's set up and offers the next step
npx shaders connect        # link this codebase to a Shaders project
npx shaders install        # pick shaders from that project; writes component files
npx shaders search "..."   # find a shader in the Pro library by describing it
npx shaders update         # pull in what changed in the editor
npx shaders open           # open your project in the Shaders app
npx shaders mcp            # add the Shaders MCP server to your agents

It detects your framework, writes to your components folder, and records what it installed in a lock file.

CLI guide

Writing Shaders code with an agent

For work in your codebase away from the canvas, give your agent the engine's skill: npx shaders skill, or npx skills add shader-effects-inc/shaders. The skill covers how layers stack and blend, masking, dynamic props, shape effects, every component, and writing new ones. npx shaders connect adds it for you. When the Shaders MCP is connected too, the skill tells your agent to design on the canvas and come back to the code once the shader is installed.

shaders.com/llms.txt indexes every docs page, and shaders.com/llms-full.txt has the full component reference with props, defaults and ranges.

Agent skill guide

Build your own component

A component is a plain object passed to defineShader: a name, its props, and what to draw at each pixel. Mount it with <CustomShader> like any other component.

import { defineShader, wgsl, transformColor, transformPosition } from 'shaders/std'

export const Halo = defineShader({
  name: 'Halo',
  props: {
    color: { default: '#ffd166', transform: transformColor },
    center: { default: { x: 0.5, y: 0.5 }, transform: transformPosition },
    radius: { default: 0.6 },
  },
  paint: wgsl`
    let d = length((uv - center) * vec2f(aspect, 1.0)) / radius;
    return vec4f(color.rgb, 1.0 - smoothstep(0.8, 1.0, d));
  `,
})

You can write the pixel part in WGSL (stable) or compose it from the std primitives (experimental). This is also what your agent writes when it designs a custom component in the app.

Custom components · Primitives reference

Free and Pro

The engine and components in this repository are free, with no account needed. The desktop app is free too: design on the canvas, export what you make, and let your agent make 200 edits a week. Reading shaders and installing code don't count toward that.

Shaders Pro is billed monthly or yearly and adds:

License

Contribute

Issues and pull requests are welcome. Read the contributing guide before starting, and for anything more than a bug fix, open an issue to discuss it before the PR.

The engine lives in packages/core, with one folder per component under src/shaders/. The framework packages are generated from it.

pnpm install
pnpm lib:build   # build every package (regenerates the registry and framework components)
pnpm test        # the engine's test suite

Say hello on Discord.


Shaders © Shader Effects, Inc.

shaders (shader-effects-inc/shaders)

Searching Database…

What is this?Shaders is a library of 200+ WebGPU visual effects (gradients, noise, glass, metal, light, distortions, transitions, blurs, cursor effects) shipped as ready-to-use components for React, Vue, Svelte, Solid and plain JavaScript.
Is this one framework, or does each framework get its own package?It is a cross-framework component library: React, Vue, Svelte, Solid and plain JS each get a first-class entry point exposing the same props.
How do I add Shaders to my project?Install the package for your framework and drop in the effect components, or use the Shaders CLI, which connects to your Shaders account, detects your framework, and writes the designed components into your components folder with a lock file to keep them in sync.
Do I need a WebGPU-capable browser?Yes, the effects render through a real WebGPU declarative API, so the target browser needs WebGPU support; the components are TypeScript, SSR safe, and used across thousands of production sites.
Is the whole thing free, or is some of it paid?The core engine, all 200+ components, the design editor, the CLI and the MCP server are free. Shaders Pro adds 1,000+ presets, 55+ ready website sections, watermark-free HD export, a Framer plugin, and unlimited version history.
Is the whole project MIT licensed?Only the engine, components and framework bindings in this repo and npm package are MIT. The design editor, presets, website sections and other shaders.com platform features are separate and have their own terms.
What does the visual design editor do?At shaders.com you design effects on an infinite canvas, tune every prop with live controls, drive props from the cursor or a timeline, then click Export Code to get the matching component tree for your framework, free with an account.
Can AI coding agents use Shaders?Yes, running npx shaders@latest install-mcp sets up an MCP server for Claude Code, Cursor, Codex, Windsurf, Copilot and others, and shaders.com/llms.txt and llms-full.txt give agents the full docs and component reference.
Can I build a custom shader component?Yes, via defineShader you create a plain object with a name, props, and per-pixel drawing logic, written in WGSL directly (stable) or composed from std primitives (experimental), then mounted like any other component.
Who is this aimed at, and how popular is it?It targets front-end and design engineers who want GPU effects without writing WGSL by hand; the project reports being used on thousands of websites by over 16,000 design engineers.
Size
8.8 MB
Stars
6.1K
Age
2mo
Commits · 90 Days