Skip to content

Commit 19c3137

Browse files
committed
chore: add PHPStan
1 parent fcdcf4c commit 19c3137

File tree

2 files changed

+21
-0
lines changed

2 files changed

+21
-0
lines changed

composer.json

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,12 @@
3232
"role": "Developer"
3333
}
3434
],
35+
"minimum-stability": "beta",
36+
"prefer-stable": true,
37+
"scripts": {
38+
"analyse:phpstan": "phpstan analyse",
39+
"clear-cache:phpstan": "phpstan clear-result-cache"
40+
},
3541
"extra": {
3642
"flarum-extension": {
3743
"title": "Mobile tab",
@@ -62,5 +68,8 @@
6268
"css": true
6369
}
6470
}
71+
},
72+
"require-dev": {
73+
"flarum/phpstan": "^2.0@beta"
6574
}
6675
}

phpstan.neon

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
includes:
2+
- vendor/flarum/phpstan/extension.neon
3+
4+
parameters:
5+
level: 5
6+
paths:
7+
- src
8+
- extend.php
9+
excludePaths:
10+
- *.blade.php
11+
checkMissingIterableValueType: false
12+
databaseMigrationsPath: ['migrations']

0 commit comments

Comments
 (0)