0.2.0 • Published 4 years ago
react-neon-components v0.2.0
react-neon-components
A small react component library to display header elements in different neon optics.
A storybook with some examples can be found at https://florianbuehler.github.io/react-neon-components/ and the source code at https://github.com/florianbuehler/react-neon-components/.
Installation
To install the package, run
npm install react-neon-componentsUsage
The different neon components can be directly imported from react-neon-components and can then be used as a standard react component.
Example
import { NeonH1 } from 'react-neon-components';
<>
...
<NeonH1 color='red' effect="flicker" fontSize="5rem">Neon</NeonH1>
...
</>Available Properties
react-neon-components currently supports the following properties:
- color /
string/ required - The color of the element. It can be every valid CSS color - e.g.red,rgb(255,0,0)or##ff0000. - fontSize /
string/ optional - The font size of the element inrem,emorpx. - effect /
string/ optional - Specifies which effect should be used. Available options areglow,flicker,subtle-flickerandpulsate. Defaults toglow. - border /
boolean/ optional - Specifies if a border should be displayed. Defaults tofalse. - reflection /
boolean/ optional - Specifies if a reflection should be displayed. Defaults tofalse.