8000 Example of pretty-printing (indenting) XML with Saxy? · Issue #115 · qcam/saxy · GitHub
[go: up one dir, main page]

Skip to content

Example of pretty-printing (indenting) XML with Saxy? #115

Open

Description

@thbar

For some time (see https://elixirforum.com/t/what-is-your-best-trick-to-pretty-print-a-xml-string-with-elixir-or-erlang/42010), I've wondered what is the best way to indent XML (like xmllint --format file.xml does), in order to make it more readable to humans.

I have came across javascript packages (https://www.npmjs.com/package/xml-formatter) which does that.

I wonder if someone has already implemented that with Saxy, ideally in a way that does not require a full in-RAM storage (simple_form), but instead streamed if possible.

Opening this issue to create a bit of discussion, and I will definitely comment back & create extra documentation if I find how to achieve that (for now I'll rely on javascript-land).

Related:

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      0