mirror of
https://github.com/Smaug123/KaTeX
synced 2025-10-12 06:28:40 +00:00
Add ignore option for class names (#1555)
* Add ignore option for class names This change adds another option for ignoring nodes for rendering similar to `ignoreTags`. The new option `ignoreClasses` can hold an array of strings representing class names that should be ignored if they are in a node's class list. This can be desirable in dynamic environments. * Adhere to CI rules for styling * Add documentation for new option * Exchange classList property with IE9 compatible code * Harmonize variable names * Add default for ignoredClasses
This commit is contained in:
@@ -82,6 +82,9 @@ in addition to two auto-render-specific keys:
|
||||
through. The default value is
|
||||
`["script", "noscript", "style", "textarea", "pre", "code"]`.
|
||||
|
||||
- `ignoredClasses`: This is a list of DOM node class names to ignore when
|
||||
recursing through. By default, this value is not set.
|
||||
|
||||
- `errorCallback`: A callback method returning a message and an error stack
|
||||
in case of an critical error during rendering. The default uses `console.error`.
|
||||
|
||||
|
Reference in New Issue
Block a user