1.0.0 • Published 4 years ago

react-randoml v1.0.0

Weekly downloads
5
License
MIT
Repository
github
Last release
4 years ago

react-randoml

NPM version NPM downloads

About

RandoML implementation for React

How to Install

First, install the library in your project by npm:

$ npm install react-randoml

Or Yarn:

$ yarn add react-randoml

Getting Started

Options

RandoML options

Returned Values

RandoML methods

Example

useRandoml hook:

import React from 'react';
import { useRandoml } from 'react-randoml';

const App = () => {
  const { choose } = useRandoml(/* object with options (if needed) */);

  const randomValue = choose();

  return (
    <h1>{randomValue}</h1>
  );
}

export default App;

withRandoml HOC:

import React from 'react';
import { withRandoml } from 'react-randoml';

const App = ({ choose }) => {
  const randomValue = choose();

  return(
    <h1>{randomValue}</h1>
  );
}

export default withRandoml(App, /* object with options (if needed) */);

License

This project is licensed under the MIT License © 2020-present Jakub Biesiada

1.0.0

4 years ago

1.0.0-beta.1

4 years ago