PHPackages                             evilspiriti/xml - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Parsing &amp; Serialization](/categories/parsing)
4. /
5. evilspiriti/xml

ActiveLibrary[Parsing &amp; Serialization](/categories/parsing)

evilspiriti/xml
===============

02PHP

Since Jun 23Pushed 4y ago1 watchersCompare

[ Source](https://github.com/EvilSpiriti/XML)[ Packagist](https://packagist.org/packages/evilspiriti/xml)[ RSS](/packages/evilspiriti-xml/feed)WikiDiscussions master Synced 3w ago

READMEChangelogDependenciesVersions (1)Used By (0)

Laravel XML made easy!
======================

[](#laravel-xml-made-easy)

[![Latest Version on Packagist](https://camo.githubusercontent.com/194ece52174428fcecd6be9718da8b40ed5d80e6cf598b0300a5c854429c503f/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f61636662656e7476656c642f786d6c2e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/acfbentveld/xml)[![Total Downloads](https://camo.githubusercontent.com/ddd0fd4f0cabfa0fbd3d34f20d95091fac7a39ff76656a688d3066eed5a641b6/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f61636662656e7476656c642f786d6c2e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/acfbentveld/xml)[![Build Status](https://camo.githubusercontent.com/3b577e034c6a4a3d7f894f332571c616a5580cf4ba2c5b99bde75e735d978903/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f41434642656e7476656c642f584d4c2f6d61737465722e7376673f7374796c653d666c61742d737175617265)](https://travis-ci.org/ACFBentveld/XML)[![StyleCI](https://camo.githubusercontent.com/a9a33ca1524a73feb4a0793a73cdeb4da5cf93fd4358c81b150cc98f1b7365b4/68747470733a2f2f6769746875622e7374796c6563692e696f2f7265706f732f3133373231333831352f736869656c643f6272616e63683d6d6173746572)](https://github.styleci.io/repos/137213815)

This package is optimized XML handling package for Laravel aiming to be easy and fast.

The main features are

- Fast XML importing with the ability to cast to classes and models
- XML exporting from (nested / value only ) arrays
- Exporting Laravel views to XML

Installation
------------

[](#installation)

You can install the package via composer:

```
composer require evilspiriti/xml
```

Usage
-----

[](#usage)

This packages comes with a facade which you can use like this `\XML::` or use it in your class like `use XML;`

In depth guides can be found here:

- [Exporting](https://github.com/EvilSpiriti/XML/blob/master/docs/export.md)
- [Importing](https://github.com/EvilSpiriti/XML/blob/master/docs/import.md)

```
$notes = XML::import("notes.xml")
    ->cast('note')->to(NoteModel::class)
    ->expect('note')->as('array')
    ->optimize('camelcase')
    ->get();
```

### Changelog

[](#changelog)

Please see [CHANGELOG](CHANGELOG.md) for more information what has changed recently.

Contributing
------------

[](#contributing)

Please see [CONTRIBUTING](CONTRIBUTING.md) for details.

### Security

[](#security)

If you discover any security related issues, please email  instead of using the issue tracker.

Credits
-------

[](#credits)

- [Wim Pruiksma](https://github.com/wimurk)
- [Amando Vledder](https://github.com/AmandoVledder)
- [All Contributors](../../contributors)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

14

—

LowBetter than 1% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity2

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity26

Early-stage or recently created project

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/11713a9cbb510ad3a853d22a3022c0798996de2924c045beeae647a549276526?d=identicon)[EvilSpiriti](/maintainers/EvilSpiriti)

---

Top Contributors

[![EvilSpiriti](https://avatars.githubusercontent.com/u/59861314?v=4)](https://github.com/EvilSpiriti "EvilSpiriti (8 commits)")

### Embed Badge

![Health badge](/badges/evilspiriti-xml/health.svg)

```
[![Health](https://phpackages.com/badges/evilspiriti-xml/health.svg)](https://phpackages.com/packages/evilspiriti-xml)
```

###  Alternatives

[mck89/peast

Peast is PHP library that generates AST for JavaScript code

19139.2M45](/packages/mck89-peast)[sauladam/shipment-tracker

Parses tracking information for several carriers, like UPS, USPS, DHL and GLS by simply scraping the data. No need for any kind of API access.

9843.5k](/packages/sauladam-shipment-tracker)[jstewmc/rtf

Read and write Rich Text Format (RTF) documents with PHP

45153.1k6](/packages/jstewmc-rtf)[tcds-io/php-jackson

A lightweight, flexible object serializer for PHP, inspired by FasterXML/jackson

113.2k10](/packages/tcds-io-php-jackson)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
