diff options
author | Radu <radu@pml4t.net> | 2023-11-24 16:52:57 -0500 |
---|---|---|
committer | Radu <radu@pml4t.net> | 2023-11-24 22:17:59 -0500 |
commit | 290f849c64c9f198f09b592daa48ecdae957375f (patch) | |
tree | fab417d5837cde3cd9b4db54dd61d59ca098a69d /README.md | |
parent | ef17d1d29212f5dc0218bfca1c30709e5a35f7b2 (diff) |
Support GFM using `remarked` and fix some bugs
- This avoids edge cases in the primitive parser I wrote.
- Add KaTeX stylesheet (cause of rendering issues, not Pronto).
- Bundle with Webpack.
Diffstat (limited to 'README.md')
-rw-r--r-- | README.md | 58 |
1 files changed, 21 insertions, 37 deletions
@@ -2,45 +2,41 @@ # ASAP -A browser extension that adds LaTeX and code support to Pronto. +A Web extension that adds Markdown and LaTeX support to Pronto. To bundle the extension, run `nix build` in the root of this repository. The -result will be available at `result/asap.zip`. +result and dependency licenses will appear at `result/asap.zip` and +`result/licenses.txt`. ## Guide -`\(`, `\[`, `$`, `$$` and the `equation`, `align`, `alignat`, `gather`, `CD` -environments invoke KaTeX. For example, +[GFM](https://github.github.com/gfm) is supported. + +A pair of `$` invokes KaTeX inline and a pair of `$$` invokes KaTeX inline or in +display mode (depending on whether the two `$$` each have their own line). For +example, ```tex -This is text and \(\pi \in \mathbb R\). -\begin{align} +This is text and $\pi \in \mathbb R$. Also, $$1 + 1 = 2$$. +$$ +\begin{align*} \sum_{n = 1}^{10} n & = \frac{10 \cdot 11} 2 \\ & = 55 -\end{align} +\end{align*} +$$ ``` -Code blocks are delimited by pairs of ```` ``` ````. +A code block with `math` as the language also invokes display mode: ````md -``` -let x = "What language is this?"; -``` -```` - -Highlight.js guesses the language, but you can also specify it after the first -```` ``` ````: - -````md -```bash -echo 'I know this one!' +```math +\begin{align} +& x + y = x \nonumber \\ +\implies & y = 0 +\end{align} ``` ```` -Inline code is delimited by pairs of `` ` `` (e.g., `` `x = 2` ``). Syntax -highlighting still occurs. The language can be specified like so: `` `import -math`{:.python}``. - ## Development The extension can be tested by [temporarily installing it in @@ -49,17 +45,5 @@ Chromium-based browsers](chrome://extensions). ## License -All the files in this repository except `licenses/`, `hljs/`, `katex/` and -`STIXTwoMath-Regular.otf` are licensed under the GNU General Public License v2.0 -only. A copy of the GNU General Public License v2.0 is available in this -repository at `licenses/GPL-2.0`. - -`hljs/` is licensed under the 3-Clause BSD License. A copy of the 3-Clause BSD -License is available in this repository at `licenses/HIGHLIGHT-JS-BSD-3-CLAUSE`. - -`katex/` is licensed under the MIT License. A copy of the MIT License is -available in this repository at `licenses/KATEX-MIT`. - -`STIXTwoMath-Regular.otf` is licensed under the SIL Open Font License. A copy -of the SIL Open Font License is available in this repository at -`licenses/STIX-OFL`. +The files in this repository (except `COPYING`) are licensed under the GNU +General Public License v2.0 only, a copy of which exists in `COPYING`. |