Skip to content

Commit d9675b6

Browse files
Update readme
1 parent 82029ad commit d9675b6

File tree

2 files changed

+12
-0
lines changed

2 files changed

+12
-0
lines changed

README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,10 @@ $users = QueryBuilder::for(User::class)
8484

8585
[Read more about appending attributes.](https://docs.spatie.be/laravel-query-builder/v2/features/appending-attributes/)
8686

87+
## ⚠ Possible breaking changes from v2 to v3
88+
89+
Please check the [CHANGELOG](CHANGELOG.md) for some notes regarding upgrading from v2 to v3.
90+
8791
## Support us
8892

8993
Learn how to create a package like this one, by watching our premium video course:

UPGRADING.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,14 @@
22

33
Because there are many breaking changes an upgrade is not that easy. There are many edge cases this guide does not cover. We accept PRs to improve this guide.
44

5+
## From v2 to v3
6+
7+
Possible changes in this version due to internal changes.
8+
9+
The package's `Spatie\QueryBuilder\QueryBuilder` class no longer extends Laravel's `Illuminate\Database\Eloquent\Builder`. This means you can no longer pass a `QueryBuilder` instance where a `Illuminate\Database\Eloquent\Builder` instance is expected. However, all Eloquent method calls get forwarded to the internal `Illuminate\Database\Eloquent\Builder`.
10+
11+
Using `$queryBuilder->getEloquentBuilder()` you can access the internal `Illuminate\Database\Eloquent\Builder`.
12+
513
## From v1 to v2
614

715
There are a lot of renamed methods and classes in this release. An advanced IDE like PhpStorm is recommended to rename these methods and classes in your code base. Use the refactor -> rename functionality instead of find & replace.

0 commit comments

Comments
 (0)