html-react-parser 1.4.12 → 2.0.0
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 +6 -1
- package/dist/html-react-parser.js +927 -740
- package/dist/html-react-parser.js.map +1 -1
- package/dist/html-react-parser.min.js +1 -1
- package/dist/html-react-parser.min.js.map +1 -1
- package/index.d.ts +3 -3
- package/index.js +7 -7
- package/lib/attributes-to-props.d.ts +2 -2
- package/lib/attributes-to-props.js +3 -3
- package/lib/dom-to-react.d.ts +3 -3
- package/lib/dom-to-react.js +7 -7
- package/lib/utilities.js +7 -7
- package/package.json +20 -19
package/README.md
CHANGED
|
@@ -41,6 +41,7 @@ parse('<p>Hello, World!</p>'); // React.createElement('p', {}, 'Hello, World!')
|
|
|
41
41
|
- [htmlparser2](#htmlparser2)
|
|
42
42
|
- [trim](#trim)
|
|
43
43
|
- [Migration](#migration)
|
|
44
|
+
- [v2.0.0](#v200)
|
|
44
45
|
- [v1.0.0](#v100)
|
|
45
46
|
- [FAQ](#faq)
|
|
46
47
|
- [Is this XSS safe?](#is-this-xss-safe)
|
|
@@ -83,7 +84,7 @@ yarn add html-react-parser
|
|
|
83
84
|
|
|
84
85
|
```html
|
|
85
86
|
<!-- HTMLReactParser depends on React -->
|
|
86
|
-
<script src="https://unpkg.com/react@
|
|
87
|
+
<script src="https://unpkg.com/react@18/umd/react.production.min.js"></script>
|
|
87
88
|
<script src="https://unpkg.com/html-react-parser@latest/dist/html-react-parser.min.js"></script>
|
|
88
89
|
<script>
|
|
89
90
|
window.HTMLReactParser(/* string */);
|
|
@@ -370,6 +371,10 @@ parse('<p> </p>', { trim: true }); // React.createElement('p')
|
|
|
370
371
|
|
|
371
372
|
## Migration
|
|
372
373
|
|
|
374
|
+
### v2.0.0
|
|
375
|
+
|
|
376
|
+
Since [v2.0.0](https://github.com/remarkablemark/html-react-parser/releases/tag/v2.0.0), Internet Explorer (IE) is no longer supported.
|
|
377
|
+
|
|
373
378
|
### v1.0.0
|
|
374
379
|
|
|
375
380
|
TypeScript projects will need to update the types in [v1.0.0](https://github.com/remarkablemark/html-react-parser/releases/tag/v1.0.0).
|