psalm-plugin-symfony/README.md

22 lines
803 B
Markdown
Raw Normal View History

2019-11-12 14:36:05 +01:00
# Symfony Psalm Plugin
2019-11-14 08:27:50 +01:00
[![Build Status](https://travis-ci.com/seferov/symfony-psalm-plugin.svg?branch=master)](https://travis-ci.com/seferov/symfony-psalm-plugin)
2019-11-12 14:36:05 +01:00
### Installation
```
composer require --dev seferov/symfony-psalm-plugin
vendor/bin/psalm-plugin enable seferov/symfony-psalm-plugin
```
2019-11-14 08:27:50 +01:00
### Features
- Detect `ContainerInterface::get()` result type
- Fixes `PossiblyInvalidArgument` for `Symfony\Component\HttpFoundation\Request::getContent`.
The plugin calculates real return type by checking the given argument and marks return type as either string or resource.
- Complains when `Container` is injected to a service. Use dependency-injection.
2019-11-14 08:27:50 +01:00
### Credits
- [@weirdan](https://github.com/weirdan) for [codeception psalm module](https://github.com/weirdan/codeception-psalm-module)