/inspirational-quotes

Get inspired 💡

Primary LanguageJavaScriptMIT LicenseMIT

Logo

Inspirational Quotes

Get inspired!

Installation

yarn add @divyanshu013/inspirational-quotes

Usage

Check out all the existing quotes or the random quote demo.

Following exports are available from the module:

  • getAll() - returns all quotes
  • getRandom() - returns a random quote

The result is in the following shape:

{
	"quote": "Always bet on JavaScript!",
	"author": "Brendan Eich"
}

Some quotes also have a source key. For example:

{
	"quote": "Life moves pretty fast. If you don’t stop and look around once in a while, you could miss it.",
	"author": "Ferris Bueller",
	"source": "Ferris Bueller’s Day Off"
}

Example

// Use require or import, either works
const { getAll, getRandom } = require('@divyanshu013/inspirational-quotes');

console.log('All quotes', getAll());
console.log('A random quote', getRandom());

Author

Attributions

Icons made by DinosoftLabs from www.flaticon.com