PHPackages                             tomasvotruba/bladestan - 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. [Testing &amp; Quality](/categories/testing)
4. /
5. tomasvotruba/bladestan

ActivePhpstan-extension[Testing &amp; Quality](/categories/testing)

tomasvotruba/bladestan
======================

PHPStan rule for static analysis of Blade templates

0.11.5(2mo ago)363584.5k—5%25[13 issues](https://github.com/bladestan/bladestan/issues)[3 PRs](https://github.com/bladestan/bladestan/pulls)3MITPHPPHP ^8.2CI passing

Since Mar 5Pushed 2mo ago5 watchersCompare

[ Source](https://github.com/bladestan/bladestan)[ Packagist](https://packagist.org/packages/tomasvotruba/bladestan)[ Fund](https://www.paypal.me/rectorphp)[ GitHub Sponsors](https://github.com/tomasvotruba)[ RSS](/packages/tomasvotruba-bladestan/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (10)Dependencies (26)Versions (26)Used By (3)

[![codecov](https://camo.githubusercontent.com/57e3071da0b1cd7204ff6fd1806325646fbcc8173b6dcf1f610ec4459c0aa4a6/68747470733a2f2f636f6465636f762e696f2f67682f626c6164657374616e2f626c6164657374616e2f67726170682f62616467652e7376673f746f6b656e3d5955564e314250444553)](https://codecov.io/gh/bladestan/bladestan)

Bladestan
=========

[](#bladestan)

Static analysis for Blade templates in Laravel projects.

Install
-------

[](#install)

```
composer require tomasvotruba/bladestan --dev
```

Configure
---------

[](#configure)

If you run PHPStan with its [extension installer](https://phpstan.org/user-guide/extension-library#installing-extensions), Bladestan will just work, if not you need to include it in the `phpstan.neon` configuration file:

```
includes:
    - ./vendor/tomasvotruba/bladestan/config/extension.neon
```

Features
--------

[](#features)

### Custom Error Formatter

[](#custom-error-formatter)

We provide custom PHPStan error formatter to better display the template errors:

- clickable template file path link to the error in blade template

```
 ------ -----------------------------------------------------------
  Line   app/Http/Controllers/PostCodexController.php
 ------ -----------------------------------------------------------
  20     Call to an undefined method App\Entity\Post::getContent().
         rendered in: post_codex.blade.php:15
 ------ -----------------------------------------------------------
```

How to use custom error formatter?

```
vendor/bin/phpstan analyze --error-format=blade
```

Credits
-------

[](#credits)

- [Can Vural](https://github.com/canvural) - this package is based on that, with upgrade for Laravel 10 and active maintenance
- [All Contributors](https://github.com/TomasVotruba/bladestan/graphs/contributors)

###  Health Score

61

—

FairBetter than 99% of packages

Maintenance86

Actively maintained with recent releases

Popularity57

Moderate usage in the ecosystem

Community32

Small or concentrated contributor base

Maturity58

Maturing project, gaining track record

 Bus Factor2

2 contributors hold 50%+ of commits

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 ~60 days

Recently: every ~95 days

Total

19

Last Release

63d ago

PHP version history (2 changes)0.1.0PHP ^8.1

0.11.0PHP ^8.2

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/924196?v=4)[Tomas Votruba](/maintainers/TomasVotruba)[@TomasVotruba](https://github.com/TomasVotruba)

![](https://www.gravatar.com/avatar/037e9a795cdd230276d7dd694957a8a3f0d125c0c698e0b5e3b870daff983f6b?d=identicon)[AJenbo](/maintainers/AJenbo)

---

Top Contributors

[![AJenbo](https://avatars.githubusercontent.com/u/204594?v=4)](https://github.com/AJenbo "AJenbo (70 commits)")[![TomasVotruba](https://avatars.githubusercontent.com/u/924196?v=4)](https://github.com/TomasVotruba "TomasVotruba (65 commits)")[![canvural](https://avatars.githubusercontent.com/u/1574232?v=4)](https://github.com/canvural "canvural (47 commits)")[![szepeviktor](https://avatars.githubusercontent.com/u/952007?v=4)](https://github.com/szepeviktor "szepeviktor (11 commits)")[![staabm](https://avatars.githubusercontent.com/u/120441?v=4)](https://github.com/staabm "staabm (3 commits)")[![spawnia](https://avatars.githubusercontent.com/u/12158000?v=4)](https://github.com/spawnia "spawnia (3 commits)")[![ondrejmirtes](https://avatars.githubusercontent.com/u/104888?v=4)](https://github.com/ondrejmirtes "ondrejmirtes (3 commits)")[![calebdw](https://avatars.githubusercontent.com/u/4176520?v=4)](https://github.com/calebdw "calebdw (2 commits)")[![robchett](https://avatars.githubusercontent.com/u/5231691?v=4)](https://github.com/robchett "robchett (2 commits)")[![williamdes](https://avatars.githubusercontent.com/u/7784660?v=4)](https://github.com/williamdes "williamdes (2 commits)")[![ziming](https://avatars.githubusercontent.com/u/679513?v=4)](https://github.com/ziming "ziming (1 commits)")[![ghbob](https://avatars.githubusercontent.com/u/1529139?v=4)](https://github.com/ghbob "ghbob (1 commits)")[![Joeri-Abbo](https://avatars.githubusercontent.com/u/34270045?v=4)](https://github.com/Joeri-Abbo "Joeri-Abbo (1 commits)")[![mrhn](https://avatars.githubusercontent.com/u/5760050?v=4)](https://github.com/mrhn "mrhn (1 commits)")[![ngmy](https://avatars.githubusercontent.com/u/864041?v=4)](https://github.com/ngmy "ngmy (1 commits)")[![owenvoke](https://avatars.githubusercontent.com/u/1899334?v=4)](https://github.com/owenvoke "owenvoke (1 commits)")[![rikvdh](https://avatars.githubusercontent.com/u/1267617?v=4)](https://github.com/rikvdh "rikvdh (1 commits)")[![Seb33300](https://avatars.githubusercontent.com/u/915273?v=4)](https://github.com/Seb33300 "Seb33300 (1 commits)")[![ThibaudDauce](https://avatars.githubusercontent.com/u/1770543?v=4)](https://github.com/ThibaudDauce "ThibaudDauce (1 commits)")

---

Tags

static analysisphpstan-extension

###  Code Quality

TestsPHPUnit

Static AnalysisRector

Code StyleECS

### Embed Badge

![Health badge](/badges/tomasvotruba-bladestan/health.svg)

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

###  Alternatives

[larastan/larastan

Larastan - Discover bugs in your code without running it. A phpstan/phpstan extension for Laravel

6.4k43.5M5.2k](/packages/larastan-larastan)[phpstan/phpstan-symfony

Symfony Framework extensions and rules for PHPStan

78768.9M1.5k](/packages/phpstan-phpstan-symfony)[phpstan/phpstan-doctrine

Doctrine extensions for PHPStan

66766.6M1.1k](/packages/phpstan-phpstan-doctrine)[tomasvotruba/type-coverage

Measure type coverage of your project

2108.9M211](/packages/tomasvotruba-type-coverage)[spaze/phpstan-disallowed-calls

PHPStan rules to detect disallowed method &amp; function calls, constant, namespace, attribute, property &amp; superglobal usages, with powerful rules to re-allow a call or a usage in places where it should be allowed.

33320.0M375](/packages/spaze-phpstan-disallowed-calls)[staabm/phpstan-dba

2912.3M2](/packages/staabm-phpstan-dba)

PHPackages © 2026

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