New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

mathlifier

Package Overview
Dependencies
Maintainers
0
Versions
20
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mathlifier - npm Package Compare versions

Comparing version

to
2.0.3

10

package.json
{
"name": "mathlifier",
"version": "2.0.2",
"version": "2.0.3",
"type": "module",

@@ -34,3 +34,11 @@ "files": [

"temml": "^0.10.29"
},
"repository": {
"type": "git",
"url": "git+https://github.com/kelvinsjk/mathlifier.git",
"directory": "packages/mathlifier"
},
"bugs": {
"url": "https://github.com/kelvinsjk/mathlifier/issues"
}
}

45

README.md

@@ -8,3 +8,3 @@ # Mathlifier

> Simpler way to render math
> A simpler way to render math on the web

@@ -46,9 +46,9 @@ A collection of tools to help render mathematics in HTML and MathML

### Dynamic mathematical content via mathlifier
### Mixing prose and math via mathlifier
When working with dynamically generated mathematical content, we find ourselves
calling the previous functions over and over. Markdown-like notation is also
easier to handle vs HTML. Because of the potential ambiguity of Markdown leading
to bugs, we use [Djot](https://djot.net/) syntax (which is very similar to
markdown).
When working with dynamically generated mathematical content interspersed with
prose, we find ourselves calling the previous functions over and over.
Markdown-like notation is also easier to handle vs HTML. Because of the
potential ambiguity of Markdown leading to bugs, we use
[Djot](https://djot.net/) syntax (which is very similar to markdown).

@@ -65,7 +65,9 @@ Mathlifier provides the `mathlifier` tagged template function, which takes Djot

Interpolation starts _math mode_ so ${x} = ${xVal}
render "x=2" in math mode.
renders "x=2" in math mode.
_Display_ and _amsmath environment_ modes start with a $ before interpolation,
spans multiple lines and ends with an empty line.
Amsmath environments are automatically closed after they end.
_Display_ and _amsmath environment_ modes start with
an additional $ before interpolation.
It spans multiple lines and ends with an empty line.
Amsmath environments are automatically closed
after they end.

@@ -78,6 +80,10 @@ $${xVal}x^2 + x - 3

If we want to *prevent* math mode and do regular interpolation (ie text), prefix with an @ symbol, like this e@${x}cellent example.
If we want to *prevent* math mode and do regular
interpolation (ie text), prefix with an @ symbol,
like this e@${x}cellent example.
Regular static math will also be converted. For example, $x=2$ and $$y=3.$$
This means that regular dollar signs must be escaped, like \\$5.
Regular static math will also be converted.
For example, $x=2$ and $$y=3.$$
This means that regular dollar signs
must be escaped, like \\$5.
`;

@@ -144,4 +150,4 @@ ```

The following functions, that were available but not documented, are removed in
V2.
The following functions, that were available in V1 but not documented, are
removed in V2.

@@ -154,4 +160,5 @@ - linebreak, newline, newParagraph

attempt to have a single source code output to web and LaTeX. We have since
achieved this goal by using Djot markup along with the new `mathlifier` tagged
template function, so they are no longer necessary.
achieved this goal by using Djot markup along with the new `mathlifier`,
`mathlifierDj` and `mathlifierTex` tagged template functions, so they are no
longer necessary.

@@ -201,3 +208,3 @@ ### Upgrading to V2

more mobile-friendly. However, our original approach of using an inline-style
makes it hard for the css Cascade to override for power users.
makes it hard for css cascade overrides for power users.

@@ -204,0 +211,0 @@ We recommend adding the following css rule to replicate the previous behavior.

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet