floki icon indicating copy to clipboard operation
floki copied to clipboard

Restrict `HTMLParser` interface to only accept binaries

Open philss opened this issue 2 years ago • 2 comments

This makes the interfaces simplier. We don't need to support iodata for now yet.

philss avatar Dec 19 '23 04:12 philss

cc/ @wojtekmach

philss avatar Dec 19 '23 04:12 philss

iodata support would be useful on Phoenix LiveView tests, for example. Today Phoenix has the content stored as iodata and converts to binary just to call parse, and because mochi_html adds the <floki> root element, for each parse we ended up with two identical binaries being created.

ypconstante avatar Dec 20 '23 03:12 ypconstante