1.0.5 • Published 6 years ago

react-string v1.0.5

Weekly downloads
16
License
MIT
Repository
github
Last release
6 years ago

React String

React String allows you to render each character of a string separately.

See it in action here.

Installation

npm install react-string

or

yarn add react-string

How it works

In this example, the characters of a string will be rendered alternatively blue and red.

import React from 'react';
import String from 'react-string';

export default () => (
  <String
    renderChar={(character, index) => (
      <span style={{ color: index % 2 ? 'red' : 'blue' }}>{character}</span>
    )}
  >
    Hello world.
  </String>
);
1.0.5

6 years ago

1.0.4

6 years ago

1.0.3

6 years ago

1.0.2

6 years ago

1.0.1

6 years ago

1.0.0

6 years ago

0.1.4

6 years ago

0.1.3

6 years ago

0.1.2

6 years ago

0.1.1

6 years ago

0.1.0

6 years ago