raster-react
TypeScript icon, indicating that this package has built-in type declarations

0.1.1 • Public • Published

How to use

Raster is built with ES Modules, so it's completely tree-shakable.

Each icon can be imported as a React component, which renders an inline SVG element. This way, only the icons that are imported into your project are included in the final bundle. The rest of the icons are tree-shaken away.

Example

Additional props can be passed to adjust the icon:

import { Heart } from 'raster-react';

const App = () => {
	return (
		<Heart
			color='#f54'
			size={13}
			radius={2}
			strokeWidth={1}
			className='h-13 w-13'
		/>
	);
};

export default App;

Props

name type default
size number 24
color string currentColor
strokeWidth number 2
radius number 1
className string

Package Sidebar

Install

npm i raster-react

Weekly Downloads

23

Version

0.1.1

License

ISC

Unpacked Size

1.34 MB

Total Files

9

Last publish

Collaborators

  • saran13raj