Skip to content

React Comfort is a React library that provides utilities for common programming tasks, that make coding in React easier and cleaner.

License

Notifications You must be signed in to change notification settings

Ruben-Arushanyan/react-comfort

Repository files navigation

You can find the full documentation on the website

Description

React Comfort is a React library that provides utilities for common programming tasks, that make coding in React easier and cleaner.

Installation

npm install react-comfort

Example

import {If, Else} from 'react-comfort'

const Bar = (props) => {
    return (
        <If condition={props.age >= 18}>
            <h2>🍺🍺🍺</h2>
            <p>Buy alcohol!</p>

            <Else>
                <h2>🚫🚫🚫</h2>
                <p>Sorry, children cannot purchase alcohol!</p>
            </Else>
        </If>
    )
}

Read our contributing guide to learn about our development process.

This project has adopted the Contributor Covenant as its Code of Conduct, and we expect project participants to adhere to it. Please read the full text so that you can understand what actions will and will not be tolerated.

Authors

License

MIT License