solid-cosha
v0.1.3
Published
A solid directive for adding colorful shadows to images.
Downloads
6
Readme
solid-cosha
A solid directive for adding colorful shadows to images (based on cosha).
Quick start
Install it:
yarn add solid-cosha
Use it:
import { cosha } from 'solid-cosha';
const App = () => {
return (
<div>
<img src="src/assets/john-cena.jpg" alt="peacemaker" use:cosha />
</div>
);
};
Config
Everything in the config is optional. The default values are:
const App = () => {
return (
<img
src="src/assets/john-cena.jpg"
alt="peacemaker"
use:cosha={{
blur: '5px',
brightness: 1,
saturation: 1,
x: 0,
y: 0,
}}
/>
);
};
License
MIT License © 2022 Robert Soriano