defuddle 0.3.1 → 0.3.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +15 -0
- package/dist/index.full.d.ts +3 -0
- package/dist/index.full.js +1 -0
- package/dist/index.js +1 -1
- package/dist/math.base.d.ts +9 -0
- package/dist/math.core.d.ts +7 -0
- package/dist/math.d.ts +2 -14
- package/dist/math.full.d.ts +8 -0
- package/package.json +20 -2
package/README.md
CHANGED
|
@@ -34,6 +34,21 @@ console.log(article.content); // HTML string of the main content
|
|
|
34
34
|
console.log(article.title); // Title of the article
|
|
35
35
|
```
|
|
36
36
|
|
|
37
|
+
### Bundles
|
|
38
|
+
|
|
39
|
+
Defuddle comes in two bundles:
|
|
40
|
+
|
|
41
|
+
**Core bundle** (~50kB), no dependencies
|
|
42
|
+
```js
|
|
43
|
+
import { Defuddle } from 'defuddle';
|
|
44
|
+
```
|
|
45
|
+
**Full bundle** (~432kB), includes advanced math conversion capabilities
|
|
46
|
+
```js
|
|
47
|
+
import { Defuddle } from 'defuddle/full';
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
The core bundle is recommended for most use cases. It still handles math content, but doesn't include fallbacks for converting between MathML and LaTeX formats. The full bundle adds the ability to create reliable `<math>` elements using `mathml-to-latex` and `temml` libraries.
|
|
51
|
+
|
|
37
52
|
### Debug mode
|
|
38
53
|
|
|
39
54
|
You can enable debug mode by passing an options object when creating a new Defuddle instance:
|