Ok guyz, you have a master degree in Graph Theory, you follow Law of Demeter
and you live on S.O.L.I.D principles ?
Let's have some Fun ! (^ω^)
Mondrian alternatives and similar libraries
Based on the "Code Analysis" category.
Alternatively, view Mondrian alternatives based on common mentions on social networks and blogs.
9.5 9.9 L2 Mondrian VS PHPStanPHP Static Analysis Tool - discover bugs in your code without running it!
9.5 9.6 L2 Mondrian VS PHP CS FixerA tool to automatically fix PHP Coding Standards issues
9.4 9.0 L2 Mondrian VS PHP Code SnifferPHP_CodeSniffer tokenizes PHP files and detects violations of a defined set of coding standards.
8.8 9.4 L2 Mondrian VS phanPhan is a static analyzer for PHP. Phan prefers to avoid false-positives and attempts to prove incorrectness rather than correctness.
7.7 8.5 L5 Mondrian VS PHP Mess DetectorPHPMD is a spin-off project of PHP Depend and aims to be a PHP equivalent of the well known Java tool PMD. PHPMD can be seen as an user friendly frontend application for the raw metrics stream measured by PHP Depend.
7.7 2.1 L4 Mondrian VS PHP MetricsBeautiful and understandable static analysis tool for PHP
6.1 9.4 L4 Mondrian VS Better Reflection:crystal_ball: Better Reflection is a reflection API that aims to improve and provide more features than PHP's built-in reflection API.
Tool helping us to analyze software projects
3.2 0.0 L2 Mondrian VS PHPCheckstylePHPCheckstyle is an open-source tool that helps PHP programmers adhere to certain coding conventions.
* Code Quality Rankings and insights are calculated and provided by Lumnify.
They vary from L1 to L5 with "L5" being the highest.
Do you think we are missing an alternative of Mondrian or a related project?
Let's have some Fun ! (ω)
It is a set of CLI tools to help you to analyse and refactor highly coupled classes. As you know Law of Demeter and S.O.L.I.D guidances, you need your classes loosely coupled. And for this, there is one only rule : ABSTRACTION
[From Hell To Kiss](./doc/img/abstracting.png)
This app provides some helpers to add abstraction into concrete classes with minimum pain.
Download the PHAR : mondrian.phar
Try to run a simple command with a few files (or a small part of a project)
$ mondrian.phar digraph /home/dev/project
This command produces a DOT file for GraphViz. Other formats are available :
- html : interactive graph with the d3.js awesome library
- svg : open standard for vector graphics (requires GraphViz)
- json : format for d3.js for example
Example with html format
$ php mondrian.php d --ignore=tests --ignore=vendor --format=html ./MyPhpProject/
Note: The generated html file does not require any dependencies nor a connection.
Running unit tests with PHPUnit
Building the documentation with phpDocumentor
Building mondrian.phar from the sources with box2
$ box.phar b
Default digraph on trismegiste/dokudoki
Which components are bottleneck ?
Reduced graph to LSP violations on trismegiste/prolog
Read the concept [here]
Read the online documentation here
And the API here (not up to date)
You can easily add plugins to this tool to make your own algorithm, coloring scheme or new generator. I try to make the API mostly decoupled, re-usable and with great SRP and OCP concerns. Look into the "About" plugin to understand a basic stub of plugin.
Packages used in this project :
- nikic/php-parser for parsing PHP
- symfony/console for creating CLI app with swag
- alom/graphviz for rendering DOT files
- symfony/finder for searching files through filesystem
- symfony/config for managing yaml configuration without headache
- D3.js for graph rendering in html
- Phar builded with Box
- William Gibson
- JS Bach
- Dream Theater