# steamdown

> Convert Markdown to Steam's markup

Latest version **0.2.1** (published 2023-04-18) · MIT license · 0 weekly downloads

> **Deprecated.** This package is deprecated.

## Install

```sh
npm install steamdown
pnpm add steamdown
yarn add steamdown
bun add steamdown
```

Provides the commands `stmd`, `steamdown`.

## Health

**Score 10/100 (F)** — status: deprecated.

Negative: deprecated.

## Facts

| | |
|---|---|
| Version | 0.2.1 |
| Published | 2023-04-18 |
| First published | 2022-08-19 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 1 |
| Unpacked size | 17.7 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Spenser Black |
| Maintainers | spenserblack |
| Keywords | steam, text, formatting, markdown |

## Links

- npm: https://www.npmjs.com/package/steamdown
- Repository: https://github.com/spenserblack/steamdown
- Homepage: https://github.com/spenserblack/steamdown#readme
- Issues: https://github.com/spenserblack/steamdown/issues
- npm.io page: https://npm.io/package/steamdown

## Dependencies (1)

- [marked](https://npm.io/package/marked.md) ^4.2.5

## Alternatives

- [mobx-react](https://npm.io/package/mobx-react.md) — 2.8M weekly downloads
- [rc-tree](https://npm.io/package/rc-tree.md) — 2.6M weekly downloads
- [@react-oauth/google](https://npm.io/package/@react-oauth/google.md) — 1.3M weekly downloads
- [@wagmi/connectors](https://npm.io/package/@wagmi/connectors.md) — 877.0K weekly downloads
- [vee-validate](https://npm.io/package/vee-validate.md) — 836.4K weekly downloads

## Recent versions

- 0.2.1 (latest) — 2023-04-18
- 0.2.0 — 2023-03-18
- 0.1.3 — 2022-11-13
- 0.1.2 — 2022-08-26
- 0.1.1 — 2022-08-19
- 0.1.0 — 2022-08-19

## README

# [steamdown][demo]

[![npm](https://img.shields.io/npm/v/steamdown)](https://www.npmjs.com/package/steamdown)
![npm](https://img.shields.io/npm/dt/steamdown)
[![CI](https://github.com/spenserblack/steamdown/actions/workflows/ci.yml/badge.svg)](https://github.com/spenserblack/steamdown/actions/workflows/ci.yml)
[![codecov](https://codecov.io/gh/spenserblack/steamdown/branch/main/graph/badge.svg?token=aclgMScPvh)](https://codecov.io/gh/spenserblack/steamdown)

Converts Markdown to [Steam's markup][format].

## Usage

### Website

Go to http://steamdown.vercel.app/

### Library

```typescript
import parse from 'steamdown';

console.log(parse(text));
```

### CLI

```bash
# read from STDIN
steamdown -
# or
cat file.md | steamdown

# read from file
steamdown file.md
```

## Differences from Markdown

View the [input spec][basic input] and [output spec][snapshots] for an
example.

### Images

Images are *not* supported. They render to links. For example,
`![example](/image.png)` becomes `[url=/image.png]example[/url]`.

### Underlines (`[u]`)

Wrapping text with `__` does *not* make it bold, but makes it underlined
(`__underlined text__`).

### Spoiler Text (`[spoiler]`)

Wrapping text with `!!!` makes it spoiler text (`!!!hidden text!!!`).

### Quote Authors

Quotes can have authors by adding `(author)` after text preceded with a `>`.
For this reason, continuing a quote on a newline *without* preceding each line
with a `>` is considered undocumented behavior.

#### Example

```markdown
>this is some text that I'm
>responding to.
(some person)
```

### Literal Text (`[noparse]`)

Steam's `[noparse]` tag instructs Steam to render text like `[b]this[/b]`
literally, without styling. In addition to rendering a `[noparse]` block,
steamdown's literal text rule will also prevent parsing of the source text.
For example, `*this*` would not be converted to `[i]this[/i]`.

#### Inline

Text can be made literal by wrapping it with `{{{` and `}}}`
(`{{{[b]The bold tag is rendered[/b]}}}`).

#### Block Level

Any lines between `{{{` and `}}}` will be rendered without
any parsing.

##### Example

```markdown
{{{
[b] is bold
[u] is underline
}}}
```

## Limitations

Steam supports tables with no borders (`[table noborder=1]`) and equal-width cells
(`[table equalcells=1]`). These are not currently supported. Syntax proposals welcome!

[demo]: https://steamdown.vercel.app/
[format]: https://steamcommunity.com/comment/Guide/formattinghelp
[basic input]: /packages/steamdown/__tests__/input/basic.md
[snapshots]: /packages/steamdown/__tests__/__snapshots__/

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