mirror of
https://github.com/Smaug123/KaTeX
synced 2025-10-08 12:38:39 +00:00
* Replace `yarn run` with `yarn` * Replace `yarn install` with `yarn` * Remove building using `npm` from node.md
41 lines
617 B
Markdown
41 lines
617 B
Markdown
---
|
|
id: node
|
|
title: Node.js
|
|
---
|
|
## npm
|
|
Install with `npm`:
|
|
|
|
```bash
|
|
npm install katex
|
|
# or globally
|
|
npm install -g katex
|
|
```
|
|
|
|
## Yarn
|
|
Install with `Yarn`:
|
|
|
|
```bash
|
|
yarn add katex
|
|
# or globally
|
|
yarn global add katex
|
|
```
|
|
|
|
## Building from Source
|
|
|
|
To build you will need Git, Node.js 6.9 or later, and Yarn.
|
|
|
|
Clone a copy of the GitHub source repository:
|
|
```bash
|
|
git clone https://github.com/Khan/KaTeX.git
|
|
cd KaTeX
|
|
```
|
|
|
|
Then install dependencies and run `build` script:
|
|
```bash
|
|
yarn
|
|
yarn build
|
|
```
|
|
|
|
> You can manually download the package and source code from
|
|
[GitHub releases](https://github.com/Khan/KaTeX/releases).
|