---
title: "solidColor"
description: "A flat fill in one color prop."
group: "paint"
groupTitle: "Painting"
categoryId: "gradients"
categorySlug: "gradients"
categoryTitle: "Gradients"
kind: "function"
sourceUrl: "https://github.com/shader-effects-inc/shaders/blob/main/packages/core/src/std/paint/gradients.ts#L64"
---

# solidColor

A flat fill in one color prop.

```ts
solidColor(color: PropRef): Paint
```

Import `gradients` from `shaders/std` and use `gradients.solidColor`.

The color's alpha passes through, so a half-transparent color gives a half-transparent layer.

## Parameters

| Name | Type | Notes |
|---|---|---|
| `color` | `PropRef` |  |

## Example

```ts
paint: solidColor(p('color'))
```

## Used by

[SolidColor](/docs/components/solidcolor)