You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For TypeScript projects, check that `domNode` is an instance of domhandler's `Element`:
180
180
181
181
```tsx
182
-
import { Element } from'domhandler/lib/node';
182
+
importparse, { Element } from'html-react-parser';
183
183
184
184
parse('<p id="replace">text</p>', {
185
185
replace: domNode=> {
@@ -372,7 +372,7 @@ TypeScript projects will need to check the types in [v1.0.0](https://github.com/
372
372
For `replace` option:
373
373
374
374
```tsx
375
-
import { Element } from'domhandler/lib/node';
375
+
importparse, { Element } from'html-react-parser';
376
376
377
377
parse('<br class="remove">', {
378
378
replace: domNode=> {
@@ -446,7 +446,7 @@ See [#62](https://github.com/remarkablemark/html-react-parser/issues/62) and [ex
446
446
447
447
#### TS Error: Property 'attribs' does not exist on type 'DOMNode'
448
448
449
-
The TypeScript error happens because `DOMNode` needs be an instance of domhandler's `Element`. See [#199](https://github.com/remarkablemark/html-react-parser/issues/199).
449
+
The TypeScript error happens because `DOMNode` needs be an instance of domhandler's `Element`. See [migration](#migration) or [#199](https://github.com/remarkablemark/html-react-parser/issues/199).
0 commit comments