Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

Is there an option to disable nesting into text elements containing HTML?

Open
#31 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
25/100
Issue type
Feature
Clarity
Needs clarification
Activity status
Stale
Tech stack
erlang
Domain
backend

Research direction

Start with the fxml_stream:parse_element/1 entry point shown in the issue and trace how nested elements inside text content are represented. Determine whether an option can preserve the body as one Erlang binary, then verify that the chosen behavior is covered by parser tests; the issue does not name specific files or tests.

Written by the indexing model from the issue text.

Description

question

Hi,

I'm probably missing somehing but I am trying to figure out if it is possible to consider the body of a particular element as sometihng that does not need to be nested into (as is done in the below example with the granular tokenizing of the HTML elements inside the "body" element). I can see the logic for the outcome I'm getting but if I would like it just as one big CDATA is there any way I can specify that?

My goal is to simply extract the "body" as one erlang binary.

Thanks,

7> fxml_stream:parse_element(<<"<message><body>?OTRv2?\n<b>[email protected]</b> has requested an <a href=\"http://otr.cypherpunks.ca/\">Off-the-Record private conversation</a>.  However, you do not have a plugin to support that.\nSee <a href=\"http://otr.cypherpunks.ca/\">http://otr.cypherpunks.ca/</a> for more information.</body></message>">>).

{xmlel,<<"message">>,[],
       [{xmlel,<<"body">>,[],
               [{xmlcdata,<<"?OTRv2?\n">>},
                {xmlel,<<"b">>,[],[{xmlcdata,<<"[email protected]">>}]},
                {xmlcdata,<<" has requested an ">>},
                {xmlel,<<"a">>,
                       [{<<"href">>,<<"http://otr.cypherpunks.ca/">>}],
                       [{xmlcdata,<<"Off-the-Record private conversation">>}]},
                {xmlcdata,<<".  However, you do not have a plugin to support that"...>>},
                {xmlel,<<"a">>,
                       [{<<"href">>,<<"http://otr.cypherpunks.ca/">>}],
                       [{xmlcdata,<<"http://otr.cypherpunks.ca/">>}]},
                {xmlcdata,<<" for more information.">>}]}]}
Dominant language
Erlang
Stars
139
Forks
44
PR merge metrics
No merged PRs in 30d

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from processone/fast_xml

All issues in processone/fast_xml

Similar issues

More Backend & API Design issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.