domhandler

Handler for htmlparser2, to get a DOM

BSD-2-CLAUSE License

Downloads
164.9M
Stars
339
Committers
23
domhandler - Latest Release

Published by fb55 over 2 years ago

  • fix: Allow Document to be a ChildNode 02387d3

https://github.com/fb55/domhandler/compare/v5.0.2...v5.0.3

domhandler -

Published by fb55 over 2 years ago

  • Fixed ChildNode as a tagged union d7f9a0f

https://github.com/fb55/domhandler/compare/v5.0.1...v5.0.2

domhandler -

Published by fb55 over 2 years ago

domhandler -

Published by fb55 over 2 years ago

Breaking:

  • Removed the deprecated normalizeWhitespace option (#614) 6503e2d
  • Updated nodes to use tagged unions for node types (#804) acc934b
    • This might break some TypeScript code

Features:

  • Added an ESM build (#806) 5582477

https://github.com/fb55/domhandler/compare/v4.3.1...v5.0.0

domhandler - v4.3.1

Published by fb55 over 2 years ago

What's Changed

  • fix(node): Correct parse5 location types (0fcbbb8)

Full Changelog: https://github.com/fb55/domhandler/compare/v4.3.0...v4.3.1

domhandler - v4.3.0

Published by fb55 almost 3 years ago

  • Add missing Node properties from parse5, add docs 3be6f56

https://github.com/fb55/domhandler/compare/v4.2.2...v4.3.0

domhandler -

Published by fb55 about 3 years ago

A breaking change was introduced in 4.2.1 that should have been a major version bump. This reverts this change.

  • Revert "refactor: Remove deprecated normalizeWhitespace option (#614)" a841df3

https://github.com/fb55/domhandler/compare/v4.2.1...v4.2.2

domhandler -

Published by fb55 about 3 years ago

  • BREAKING, REVERTED IN 4.2.2: Removed the deprecated normalizeWhitespace option (#614) 018ddf9
    • This should not have been part of this release. 4.2.2 adds the option again.

Fixes:

  • fix: Update end index for text events (#621) d88e5b0
  • fix: Have isText return whether the node is a text node c323224

Diverse:

  • Add descriptions for Node classes 2475d2e
domhandler -

Published by fb55 over 3 years ago

New features:

  • Node improvements d5422c2
    • feat(node): Add type check functions
      • Eg. isDocument, isTag. Useful for determining if a node matches a particular type.
    • Make cloneNode return the passed type
      • Eg. cloneNode called with a Text node will now return a Text node.

https://github.com/fb55/domhandler/compare/v4.1.0...v4.2.0

domhandler -

Published by fb55 over 3 years ago

  • fix: All elements should have type: tag in xmlMode 3977aab
  • Bump domelementtype from 2.1.0 to 2.2.0 86a6f84

https://github.com/fb55/domhandler/compare/v4.0.0...v4.1.0

domhandler -

Published by fb55 almost 4 years ago

Features:

  • Add parse5 DOM extensions to types and add support in cloneNode bde2dc5
  • Add dedicated Document class de7c6d0
  • Add a root element to tree 4b8d326
    • BREAKING: Some nodes will now have a parent node where they did not have one before.

Refactors:

  • Remove _ from private property names 340fcd8
    • BREAKING: This might break your code if you were using private properties previously, eg. in a custom handler.

Fixes:

  • Clone indices as well (#352 by @neet) ea60538

Misc:

  • Run test on ppc64le as well (#398 by @nageshlop) 3d3c278

https://github.com/fb55/domhandler/compare/v3.3.0...v4.0.0

domhandler -

Published by fb55 about 4 years ago

  • Add cloneNode method & function 5babe0d

https://github.com/fb55/domhandler/compare/v3.2.0...v3.3.0

domhandler -

Published by fb55 about 4 years ago

  • Make DOM serializable by Jest
    • Jest now properly renders the produced DOM in snapshots.
domhandler -

Published by fb55 about 4 years ago

  • package.json improvements:
    • Publish only lib folder (#263 by @TrySound)
    • Add types entry (fixes #132)
    • Add sideEffects: false (#232 by @ericjeney)
  • Add access modifiers across the codebase
  • Improve test coverage
  • Update funding information
domhandler - Port to TypeScript, Jest

Published by fb55 about 5 years ago

The withDomLvl1 option was removed. Instead, there are now three different types of nodes, which all have a backing class that adds all of the previously available DOM level 1 properties by default.

Exports were changed slightly.