// Error muncul saat extends Controller
namespace App\Http\Controllers;

use App\Http\Controllers\Controller; // <- error di sini

class PostController extends Controller
{
    public function index()
    {
        return view('posts.index');
    }
}