• Home
  • History
  • Annotate
Name Date Size #Lines LOC

..22-Nov-2021-

xml/H22-Nov-2021-16157

xmlns/1.0/H22-Nov-2021-308

LICENSEH A D22-Nov-20211.1 KiB1915

README.mdH A D22-Nov-20211.3 KiB3423

package.jsonH A D22-Nov-20212 KiB5251

xmlchars.d.tsH A D22-Nov-20219.1 KiB17168

xmlchars.js.mapH A D22-Nov-20213 KiB11

README.md

1Utilities for determining whether characters belong to character classes defined
2by the XML specs.
3
4## Organization
5
6It used to be that the library was contained in a single file and you could just
7import/require/what-have-you the `xmlchars` module. However, that setup did not
8work well for people who cared about code optimization. Importing `xmlchars`
9meant importing *all* of the library and because of the way the code was
10generated there was no way to shake the resulting code tree.
11
12Different modules cover different standards. At the time this documentation was
13last updated, we had:
14
15* `xmlchars/xml/1.0/ed5` which covers XML 1.0 edition 5.
16* `xmlchars/xml/1.0/ed4` which covers XML 1.0 edition 4.
17* `xmlchars/xml/1.1/ed2` which covers XML 1.0 edition 2.
18* `xmlchars/xmlns/1.0/ed3` which covers XML Namespaces 1.0 edition 3.
19
20## Features
21
22The "things" each module contains can be categorized as follows:
23
241. "Fragments": these are parts and pieces of regular expressions that
25correspond to the productions defined in the standard that the module
26covers. You'd use these to *build regular expressions*.
27
282. Regular expressions that correspond to the productions defined in the
29standard that the module covers.
30
313. Lists: these are arrays of characters that correspond to the productions.
32
334. Functions that test code points to verify whether they fit a production.
34