@rickbrown/use-star-wars-quote

1.0.1 • Public • Published

@rickbrown/use-star-wars-quote

a custom React hook the provides a random quote from the star wars films. NPM JavaScript Style Guide

Install

yarn add @rickbrown/use-star-wars-quote

Usage

import React from 'react';
import { useStarWarsQuote } from '@rickbrown/use-star-wars-quote';

const App = () => {
  const { quote, loading } = useStarWarsQuote();
  return <div>{loading ? <p>loading..</p> : <p>{quote}</p>}</div>;
};

export default App;

License

MIT © RickBr0wn


This hook is created using create-react-hook.

Readme

Keywords

none

Package Sidebar

Install

npm i @rickbrown/use-star-wars-quote

Weekly Downloads

0

Version

1.0.1

License

MIT

Unpacked Size

569 kB

Total Files

22

Last publish

Collaborators

  • rickbrown