Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,18 +25,18 @@ When you are using [`phpstan/extension-installer`](https://github.com/phpstan/ex
<details>
<summary>Manual installation</summary>

If you don't want to use `phpstan/extension-installer`, include `extension.neon` in your project's PHPStan config:
If you don't want to use `phpstan/extension-installer`, include both files in your project's PHPStan config:

```
```neon
includes:
- vendor/mglaman/phpstan-drupal/extension.neon
- vendor/mglaman/phpstan-drupal/rules.neon
```

To include Drupal specific analysis rules, include this file:
`extension.neon` adds Drupal's types and services. `rules.neon` adds the Drupal rules. Two of those rules also load files for the rest of the analysis: `LoadIncludes` loads the file a `ModuleHandlerInterface::loadInclude()` call includes, and `ModuleLoadInclude` does the same for `module_load_include()`. Without `rules.neon`, functions from those files are reported as not found:

```
includes:
- vendor/mglaman/phpstan-drupal/rules.neon
Function locale_translation_flush_projects not found.
```
</details>

Expand Down
Loading