title: how to update laravel cache (redis driver) with paginate after delete or update a row
body: <p>I want to cache all users with pagination and update cache after any changes on user table. this is my method. i will be glad anyone help me.</p>
  
  <pre><code>public function GetAll()
  {
      $page = request()-&gt;page;
      $users = Cache::remember('users'.$page, 600, function () {
          return User::paginate(12);
      });
  
      return response()-&gt;json(['success' =&gt; $users], 200);
  }
  </code></pre>