marcuslankenau

marcuslankenau

Elixml - XML library

I feel kind of stuck with the absence of a proper xml library for Elixir. Currently I use SweetXML which was ok for me more or less to parse the xml content that I receive. But it doen’t feel natural to use.

Now I have to generate xml content as well. I have use cases like cutting nodes (with xpath) from one document, enriching that part with other data and generating a new document. I don’t feel like I can do that easily with SweetXML or floki (that I really like).

I put something together that almost covers what I need, have to continue on it. Maybe someone is interested in the project as well:

https://github.com/mlankenau/elixml

Marcus

Most Liked

OvermindDL1

OvermindDL1

I use Meeseeks for both HTML and XML parsing, it’s awesome for both. The CSS and XPath selectors are supported on both HTML and XML parsing in it.

It does require having Rust’s compiler toolchain installed though.

OvermindDL1

OvermindDL1

For note, the BEAM has a built-in xml library called xmerl (actually very powerful with multiple processing methods). :slight_smile:

However, being built-in it is very erlang’y, so elixir XML implementations and/or wrappers are nice. :slight_smile:

marcuslankenau

marcuslankenau

We have a couple of datasource (SOAP/XML, FTP/XML). We transform this data to json that we use internally. Normally we transform one XML to one JSON document. But there are exceptions where we need to combine different XMLs to reuse our existing mappings. I am not keen to use XML but i have to.

Where Next?

Popular in Announcing Top

danschultzer
None of the current solutions worked well for me, so I went ahead and built a user management system from scratch. This project took far...
548 29377 241
New
mathieuprog
Hello :waving_hand: Allow me to introduce you to Tz, an alternative time zone database support to Tzdata. Why another library? First a...
New
jakub-zawislak
Hi everyone, I’m coming from the Symfony (PHP) framework. I like Phoenix, but it has a one thing that was build much better in the Symfo...
New
Crowdhailer
The latest release of Ace (0.10.0) includes serving content over HTTP/2. I have started writing a webserver to teach my self more about...
New
msaraiva
Surface is an experimental library built on top of Phoenix LiveView and its new LiveComponent API that aims to provide a more declarative...
564 43622 214
New
mplatts
With HEEX released we decided to start a components library using Tailwind CSS - check it out here: Petal Components. We also have a boi...
New
bryanjos
Hi, I wanted share a small library we at Revelry Labs made for rendering react components from the server side. There are instructions fo...
New
ahamez
Hi everyone, I’ve been working on this protobuf library for 3 years. We use it in the company I work for, EasyMile, to communicate with ...
New
tmbb
I’ve decided to create this topic to discuss optimization possibilities for something like Phoenix LiveView. I’ve created this topic unde...
144 10187 141
New
kevinlang
Hey all, We have made an Ecto3 Adapter for SQLite3, ecto_sqlite3! We have successfully on-boarded the full suite of integration tests (...
New

Other popular topics Top

aadeshere1
I have a another noob question about loop. Since elixir is immutable, while loop is not directly possible. total = 10 while total != 0 ...
New
New
chrismccord
As promised, the first release candidate of Phoenix 1.3.0 is out! This release focuses on code generators with improved project structure...
New
gshaw
What is the idiomatic way of matching for not nil in Elixir? E.g., First way: defp halt_if_not_signed_in(conn, signed_in_account) when...
New
electic
Hi, I am new to Elixir. I am trying to use the DateTime component to insert a date into MySQL however the there seems to be no way to fo...
New
stefanchrobot
What’s the safe way to decode a JSON string into a struct? I want to avoid calling String.to_atom. Jason.decode can give me a map with st...
New
dokuzbir
I want to highlight html closing tags when i click a html tag. That works in .html files but doesnt work for html.eex templates. How can...
New
saif
Hello everyone, Long time lurker first time poster here. I’ve recently begun working on Elixir full-time again! :raised_hands: It’s been...
New
dblack
I’ve got an issue with an app and I’ve no idea of how to troubleshoot it. I’m hoping someone here might have seen something similar. I p...
New
AstonJ
Seen any cool LiveView demos, sample apps or examples? Please post them here! :003:
New

Latest on Elixir Forum

Elixir Forum

We're in Beta

About us Mission Statement