# react-librarything-shelf

> A React widget for displaying a user's public book shelf

Latest version **1.0.2** (published 2021-01-10) · MIT license · 0 weekly downloads

## Install

```sh
npm install react-librarything-shelf
pnpm add react-librarything-shelf
yarn add react-librarything-shelf
bun add react-librarything-shelf
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.2 |
| Published | 2021-01-10 |
| First published | 2021-01-10 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 2 |
| Unpacked size | 34.2 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Kyle Karpack |
| Maintainers | kkarpack |

## Links

- npm: https://www.npmjs.com/package/react-librarything-shelf
- Repository: https://github.com/kylekarpack/react-librarything-shelf
- npm.io page: https://npm.io/package/react-librarything-shelf

## Dependencies (2)

- [reactjs-popup](https://npm.io/package/reactjs-popup.md) ^2.0.4
- [@babel/runtime](https://npm.io/package/@babel/runtime.md) ^7.11.0

## Recent versions

- 1.0.2 (latest) — 2021-01-10
- 1.0.1 — 2021-01-10

## README

# react-librarything-shelf
![build](https://github.com/kylekarpack/react-librarything-shelf/workflows/build/badge.svg) ![CodeQL](https://github.com/kylekarpack/react-librarything-shelf/workflows/CodeQL/badge.svg) 
[![Maintainability Rating](https://sonarcloud.io/api/project_badges/measure?project=kylekarpack_react-librarything-shelf&metric=sqale_rating)](https://sonarcloud.io/dashboard?id=kylekarpack_react-librarything-shelf) [![Coverage](https://sonarcloud.io/api/project_badges/measure?project=kylekarpack_react-librarything-shelf&metric=coverage)](https://sonarcloud.io/dashboard?id=kylekarpack_react-librarything-shelf)

This React component allows you to display a user's LibraryThing books in a React application. It's a lot like the LibraryThing JavaScript widget, but allows for more customization, and React-like usage.

## Demo
[Storybook demo page](https://kylekarpack.github.io/react-librarything-shelf/)

![Example image](/sample/sample.png)

## Installation

```
npm install --save react-librarything-shelf
```
or
```
yarn add react-librarything-shelf
```

## Usage

```jsx
import React from "react";
import { LibrarythingBookshelf } from "react-librarything-shelf";

export default function App() {
	return (
		<LibrarythingBookshelf userId="USER_ID_HERE" apiKey="API_KEY_HERE" />
	);
}
```

## Customization

You can also set some options as supported by the Goodreads API:

| Option | Type | Description | Default |
| ------ | ---- | ----------- | ------- |
| sort  | string | The order in which to sort the results returned | entry_REV
| max  | number | The maximum number of books to be returned | 10
| showDetails  | boolean | Show the author and title | false
| reviewsOnly  | boolean | Show only books with review | false
| tagList  | string | Comma-separated tags to filter by | ""
| width | number | Minimum width allowed for each book | 100
| details | boolean | Whether to show book details like book title, author, and summary | false

## Development
- `yarn start` to watch changes and build
- `yarn storybook` to launch storybook for testing

---
_Source: https://npm.io/package/react-librarything-shelf · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
