# docs-markdown

> Opinionated starter for Node.js + TypeScript libraries

Latest version **1.2.0** (published 2020-04-28) · MIT license · 0 weekly downloads

## Install

```sh
npm install docs-markdown
pnpm add docs-markdown
yarn add docs-markdown
bun add docs-markdown
```

Provides the command `docs-markdown`.

## Health

**Score 35/100 (D)** — status: abandoned.

Positive: has types; no vulnerabilities; high quality score.

Warnings: low downloads; no esm support.

Negative: abandoned.

## Facts

| | |
|---|---|
| Version | 1.2.0 |
| Published | 2020-04-28 |
| First published | 2020-04-16 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Node | >=10.0.0 |
| Dependencies | 2 |
| Unpacked size | 18.2 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 68 |
| Author | Anand Chowdhary |
| Maintainers | anandchowdhary |
| Keywords | node.js, typescript, javascript, library |

## Links

- npm: https://www.npmjs.com/package/docs-markdown
- Repository: https://github.com/AnandChowdhary/docs-markdown
- Homepage: https://anandchowdhary.github.io/docs-markdown/
- Issues: https://github.com/AnandChowdhary/docs-markdown/issues
- npm.io page: https://npm.io/package/docs-markdown

## Dependencies (2)

- [dotenv](https://npm.io/package/dotenv.md) ^8.2.0
- [googleapis](https://npm.io/package/googleapis.md) ^49.0.0

## Alternatives

- [@openai/codex-sdk](https://npm.io/package/@openai/codex-sdk.md) — 731.4K weekly downloads
- [babel-plugin-transform-react-jsx](https://npm.io/package/babel-plugin-transform-react-jsx.md) — 565.0K weekly downloads
- [babel-helper-remove-or-void](https://npm.io/package/babel-helper-remove-or-void.md) — 508.5K weekly downloads
- [@pnpm/store-controller-types](https://npm.io/package/@pnpm/store-controller-types.md) — 186.9K weekly downloads
- [react-native-signature-canvas](https://npm.io/package/react-native-signature-canvas.md) — 155.6K weekly downloads

## Recent versions

- 1.2.0 (latest) — 2020-04-28
- 1.1.0 — 2020-04-28
- 1.0.1 — 2020-04-16
- 1.0.0 — 2020-04-16

## README

# 📝 Docs Markdown

Convert a Google Docs file (API response) to Markdown

[![Node CI](https://img.shields.io/github/workflow/status/AnandChowdhary/docs-markdown/Node%20CI?label=GitHub%20CI&logo=github)](https://github.com/AnandChowdhary/docs-markdown/actions)
[![Travis CI](https://img.shields.io/travis/AnandChowdhary/docs-markdown?label=Travis%20CI&logo=travis%20ci&logoColor=%23fff)](https://travis-ci.org/AnandChowdhary/docs-markdown)
[![Coverage](https://coveralls.io/repos/github/AnandChowdhary/docs-markdown/badge.svg?branch=master&v=2)](https://coveralls.io/github/AnandChowdhary/docs-markdown?branch=master)
[![Dependencies](https://img.shields.io/librariesio/release/npm/docs-markdown)](https://libraries.io/npm/docs-markdown)
[![License](https://img.shields.io/npm/l/docs-markdown)](https://github.com/AnandChowdhary/docs-markdown/blob/master/LICENSE)
[![Vulnerabilities](https://img.shields.io/snyk/vulnerabilities/npm/docs-markdown.svg)](https://snyk.io/test/npm/docs-markdown)
[![Based on Node.ts](https://img.shields.io/badge/based%20on-node.ts-brightgreen)](https://github.com/AnandChowdhary/node.ts)
[![npm type definitions](https://img.shields.io/npm/types/docs-markdown.svg)](https://unpkg.com/browse/docs-markdown/dist/index.d.ts)
[![npm package](https://img.shields.io/npm/v/docs-markdown.svg)](https://www.npmjs.com/package/node.ts)
[![npm downloads](https://img.shields.io/npm/dw/docs-markdown)](https://www.npmjs.com/package/node.ts)
[![Contributors](https://img.shields.io/github/contributors/AnandChowdhary/docs-markdown)](https://github.com/AnandChowdhary/docs-markdown/graphs/contributors)
[![semantic-release](https://img.shields.io/badge/%20%20%F0%9F%93%A6%F0%9F%9A%80-semantic--release-e10079.svg)](https://github.com/semantic-release/semantic-release)

[![npm](https://nodei.co/npm/docs-markdown.png)](https://www.npmjs.com/package/docs-markdown)

## 💡 Usage

Install the package from [npm](https://www.npmjs.com/package/docs-markdown):

```bash
npm install docs-markdown
```

Import and use:

```ts
import { googleDocsToMarkdown } from "docs-markdown";
import { google } from "googleapis";
import { writeFileSync } from "fs";
const oauth2Client = new google.auth.OAuth2(); // Authenticate

const docs = google.docs("v1");
const file = await docs.documents.get({
  documentId: "Google Docs document ID",
  auth: oauth2Client,
});

const markdown = googleDocsToMarkdown(file.data);
writeFileSync("file.md", markdown);
```

## ⭐️ Features

- [x] Paragraphs
- [x] Headings, titles, subtitles
- [x] Bold, italic
- [x] Lists
- [x] Links
- [ ] Images
- [ ] Tables
- [ ] Header, footer

## 👩‍💻 Development

Build TypeScript:

```bash
npm run build
```

## 📄 License

[MIT](./LICENSE) © [Anand Chowdhary](https://anandchowdhary.com)

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