PHPackages                             heartsentwined/yaml - 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. heartsentwined/yaml

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

heartsentwined/yaml
===================

Wrapper around Symfony's Yaml parser - added \_\_DIR\_\_ support.

v2.0.4(9y ago)313.1k↓50%3ISCPHPPHP &gt;=5.3.3

Since Sep 17Pushed 9y ago1 watchersCompare

[ Source](https://github.com/heartsentwined/php-yaml)[ Packagist](https://packagist.org/packages/heartsentwined/yaml)[ Docs](https://github.com/yalesov/php-yaml)[ RSS](/packages/heartsentwined-yaml/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependencies (3)Versions (9)Used By (0)

Yalesov\\Yaml
=============

[](#yalesovyaml)

[![Build Status](https://camo.githubusercontent.com/87c34a8425899255f3a8a024356be2ae865ce6fc07d6b3cf1f0219108745dc0e/68747470733a2f2f7472617669732d63692e6f72672f79616c65736f762f7068702d79616d6c2e737667)](https://travis-ci.org/yalesov/php-yaml)

Wrapper around Symfony's Yaml parser - added `__DIR__` support.

Installation
============

[](#installation)

[Composer](http://getcomposer.org/):

```
{
  "require": {
    "yalesov/yaml": "2.*"
  }
}
```

Usage
=====

[](#usage)

Two constants added:

- `__DIR__`: behave as expected
- `___DIR___` (an extra underscore around): literal `__DIR__`

Parse a Yaml file `foo/bar.yml`:

```
use Yalesov\Yaml\Yaml;
$parsedArray = Yaml::parse('foo/bar.yml');
```

Parse a Yaml string `foo: bar` (of course, neither `__DIR__` nor `___DIR___` would be available)

```
use Yalesov\Yaml\Yaml;
$parsedArray = Yaml::parse('foo: bar');
```

###  Health Score

34

—

LowBetter than 77% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity27

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity63

Established project with proven stability

 Bus Factor1

Top contributor holds 88.9% 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.

###  Release Activity

Cadence

Every ~198 days

Recently: every ~0 days

Total

8

Last Release

3596d ago

Major Versions

1.0.2 → v2.0.02016-07-05

### Community

Maintainers

![](https://www.gravatar.com/avatar/e2fd4399d9df9ec84c5064fc5b9fcdaa3e6edf9049882227efa46f24b40db67b?d=identicon)[heartsentwined](/maintainers/heartsentwined)

---

Top Contributors

[![yalesov](https://avatars.githubusercontent.com/u/20264293?v=4)](https://github.com/yalesov "yalesov (8 commits)")[![CaporalDead](https://avatars.githubusercontent.com/u/1705597?v=4)](https://github.com/CaporalDead "CaporalDead (1 commits)")

---

Tags

yamlyml

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/heartsentwined-yaml/health.svg)

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

###  Alternatives

[mustangostang/spyc

A simple YAML loader/dumper class for PHP

73240.3M172](/packages/mustangostang-spyc)[hassankhan/config

Lightweight configuration file loader that supports PHP, INI, XML, JSON, and YAML files

97513.5M170](/packages/hassankhan-config)

PHPackages © 2026

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