01 - Preheat oven to 400°F.
02 - In a large ovenproof baking dish, combine cherry tomatoes, sun-dried tomatoes, garlic, and 2 tablespoons olive oil. Generously season with salt, black pepper, oregano, and red pepper flakes if desired. Toss mixture to coat evenly.
03 - Place feta block at the center of the dish, nestling among tomatoes. Drizzle 1 tablespoon olive oil over feta and season lightly with black pepper.
04 - Transfer baking dish to oven. Bake for 25–30 minutes until tomatoes burst and feta is softened, with lightly golden edges.
05 - While cheese and tomatoes bake, heat a large skillet over medium heat. Add 1 tablespoon olive oil and the sliced onions. Cook, stirring occasionally, for 15–20 minutes until onions are deeply caramelised and golden brown. Set aside once done.
06 - Bring a large pot of salted water to a boil. Add dried pasta and cook until al dente according to package directions. Reserve 1/2 cup pasta water, then drain pasta thoroughly.
07 - Remove baking dish from oven. Immediately add caramelised onions and chopped basil to the dish. Stir together, gently breaking up feta to blend into a creamy sauce.
08 - Add cooked pasta to dish and toss to coat all ingredients. Gradually add reserved pasta water as needed until sauce reaches desired creaminess.
09 - Serve promptly, garnished with extra basil and a drizzle of olive oil if preferred.