Search results while typing

You can use a route that takes the search query and returns a JSON object with the results.

This route can then be called by your frontend code.