Skip to content

Commit

Permalink
Update 5.Entities.md
Browse files Browse the repository at this point in the history
  • Loading branch information
amitguptagwl authored Jan 11, 2022
1 parent bf5d224 commit 7ab5891
Showing 1 changed file with 19 additions and 19 deletions.
38 changes: 19 additions & 19 deletions docs/v4/5.Entities.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,11 @@ You can define your own entities using DOCTYPE. FXP by default supports followin

| Entity name | Character | Decimal reference | Hexadecimal reference |
| :---------- | :-------- | :---------------- | :-------------------- |
| quot | " | " | " |
| amp | & | & | & |
| apos | ' | ' | ' |
| lt | < | &#60; | &#x3C; |
| gt | > | &#62; | &#x3E; |
| quot | " | `&#34;` | `&#x22;` |
| amp | & | `&#38;` | `&#x26;` |
| apos | ' | `&#39;` | `&#x27;` |
| lt | < | `&#60;` | `&#x3C;` |
| gt | > | `&#62;` | `&#x3E;` |

However, since the entity processing can impact the parser's performance drastically, you can use `processEntities: false` to disable it.

Expand Down Expand Up @@ -117,19 +117,19 @@ Following HTML entities are supported by the parser by default when `htmlEntitie

| Result | Description | Entity Name | Entity Number |
| :----- | :--------------------------------- | :---------- | :------------ |
| | non-breaking space | &nbsp; | &#160; |
| < | less than | &lt; | &#60; |
| > | greater than | &gt; | &#62; |
| & | ampersand | &amp; | &#38; |
| " | double quotation mark | &quot; | &#34; |
| ' | single quotation mark (apostrophe) | &apos; | &#39; |
| ¢ | cent | &cent; | &#162; |
| £ | pound | &pound; | &#163; |
| ¥ | yen | &yen; | &#165; |
|| euro | &euro; | &#8364; |
| © | copyright | &copy; | &#169; |
| ® | registered trademark | &reg; | &#174; |
|| Indian Rupee | &inr; | &#8377; |
| | non-breaking space | `&nbsp;` | `&#160;` |
| < | less than | `&lt;` | `&#60;` |
| > | greater than | `&gt;` | `&#62;` |
| & | ampersand | `&amp;` | `&#38;` |
| " | double quotation mark | `&quot;` | `&#34;` |
| ' | single quotation mark (apostrophe) | `&apos;` | `&#39;` |
| ¢ | cent | `&cent;` | `&#162;` |
| £ | pound | `&pound;` | `&#163;` |
| ¥ | yen | `&yen;` | `&#165;` |
|| euro | `&euro;` | `&#8364;` |
| © | copyright | `&copy;` | `&#169;` |
| ® | registered trademark | `&reg;` | `&#174;` |
|| Indian Rupee | `&inr;` | `&#8377;` |
---

In future version of FXP, we'll be supporting more features of DOCTYPE such as `ELEMENT`, reading content for an entity from a file etc.
Expand All @@ -148,4 +148,4 @@ let result = parser.parse(xmlData);

This way, you can also override the default entities.

[> Next: HTML Document Parsing](./6.HTMLParsing.md)
[> Next: HTML Document Parsing](./6.HTMLParsing.md)

0 comments on commit 7ab5891

Please sign in to comment.