Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

andrews-quest's avatar

Method Inertia\ResponseFactory::scroll does not exist.

Hi, I'm trying to apply the Inertia's infinite scroll feature and I've set up the index in a Controller like that:

public function index(): Response
    {
		return Inertia::scroll('calls', [
			'calls' => Inertia::scroll(
				Call::orderBy('date', 'desc')
					->orderBy('time', 'desc')
					->paginate()),
			'operators' => Operator::all()
			]);
    }

But I receive the error 'Method Inertia\ResponseFactory::scroll does not exist.'

Googling this doesn't seem to work. I will appreciate any help.

0 likes
2 replies
JussiMannisto's avatar

It's a brand new method and your Inertia version isn't up to date. You need to update the Composer and NPM packages.

composer update inertiajs/inertia-laravel

// Replace with the adapter you're using.
npm update @inertiajs/react 
1 like

Please or to participate in this conversation.