1.8.2 • Published 5 months ago

@unified-latex/unified-latex-util-argspec v1.8.2

Weekly downloads
-
License
MIT
Repository
github
Last release
5 months ago

unified-latex-util-argspec

What is this?

Tools to deal with xparse argument signatures. (E.g., "o m" for optional followed by mandatory argument).

When should I use this?

If you are working on the internals of unified-latex.

Install

npm install @unified-latex/unified-latex-util-argspec

This package contains both esm and commonjs exports. To explicitly access the esm export, import the .js file. To explicitly access the commonjs export, import the .cjs file.

Functions

parse(str)

Parse an xparse argument specification string to an AST. This function caches results. Don't mutate the returned AST!

function parse(str: String): ArgSpec.Node[];

Parameters

ParamTypeDescription
strString* LaTeX string input

printRaw(node, root)

Print an xparse argument specification AST to a string.

function printRaw(
  node: string | ArgSpec.Node | (string | ArgSpec.Node)[],
  root: Boolean
): string;

Parameters

ParamType
nodeOmitted
rootBoolean
1.8.2

5 months ago

1.8.1

9 months ago

1.8.0

11 months ago

1.7.1

1 year ago

1.7.0

1 year ago

1.6.1

1 year ago

1.6.0

1 year ago

1.4.2

2 years ago

1.4.0

2 years ago

1.3.1

2 years ago

1.3.0

2 years ago

1.2.2

3 years ago

1.2.0

3 years ago

1.1.0

3 years ago

1.2.1

3 years ago

1.0.11

3 years ago

1.0.10

3 years ago

1.0.12

3 years ago

1.0.8

3 years ago

1.0.7

3 years ago

1.0.6

3 years ago

1.0.5

3 years ago

1.0.0

3 years ago