# epub-kit

> A suite of tools for working with epubs

Latest version **1.2.4** (published 2020-05-16) · ISC license · 0 weekly downloads

## Install

```sh
npm install epub-kit
pnpm add epub-kit
yarn add epub-kit
bun add epub-kit
```

## 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.2.4 |
| Published | 2020-05-16 |
| First published | 2020-05-01 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 6 |
| Unpacked size | 30.6 KB |
| Known vulnerabilities | 0 (+17 in 1 direct dependencies) |
| Install scripts | no |
| Author | Joe Pitts |
| Maintainers | pittsy24 |
| Keywords | epub, book, reader, metadata, ebook |

## Links

- npm: https://www.npmjs.com/package/epub-kit
- npm.io page: https://npm.io/package/epub-kit

## Dependencies (6)

- [rimraf](https://npm.io/package/rimraf.md) ^3.0.2
- [xmldoc](https://npm.io/package/xmldoc.md) ^1.1.2
- [xmldom](https://npm.io/package/xmldom.md) ^0.3.0
- [archiver](https://npm.io/package/archiver.md) ^4.0.1
- [@types/xmldom](https://npm.io/package/@types/xmldom.md) ^0.1.29
- [node-stream-zip](https://npm.io/package/node-stream-zip.md) ^1.9.1

## Recent versions

- 1.2.4 (latest) — 2020-05-16
- 1.2.3 — 2020-05-04
- 1.2.2 — 2020-05-03
- 1.2.1 — 2020-05-02
- 1.2.0 — 2020-05-02
- 1.1.3 — 2020-05-01
- 1.1.2 — 2020-05-01

## README

### ePub-kit

ePub-kit is a collection of tools for working with epubs.

## Installation

```npm install epub-kit```

Or, to install globally:

```npm install -g epub-kit```

## Usage
```javascript
const Book = require("epub-kit");
let myEpub = new Book("/path/to/my/book.epub");
myEpub.read()
.then(data => {
    // work with data
});

let info = myEpub.getData(["author", "title"]);
console.log(info) -> {"author": "Andy Weir", "title": "The Martian"}

```
Where data is an object with the following fields.

| Field         | Data Type          | Example        |
| ------------- |--------------------| ---------------|
| title         |string  |The Martian     |
| identifier    |string |9781101905005   |
| language      |string  |en              |
| creator       |string or undefined |Andy Weir       |
| contributor   |string or undefined |Eric White      |
| coverage      |string or undefined |London          |
| date          |string or undefined |2000-01-01T00:00:00Z            |
| description   |string or undefined |Six days ago, astronaut Mark Watney became one of the first people to walk on Mars...       |
| format       |string or undefined |411 Pages      |
| publisher       |string or undefined |Broadway Books       |
| relation       |string or undefined |A related resource        |
| publisher       |string or undefined |Broadway Books       |
| rights       |string or undefined |All rights reserved       |
| publisher       |string or undefined |Broadway Books       |
| source       |string or undefined |A related resource from which the described resource is derived.|
| subject       |string or undefined |Adventure stories       |
| type       |string or undefined |Text |

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