01 - Preheat the oven to 400°F (200°C).
02 - In a large ovenproof baking dish, combine cherry tomatoes, sun-dried tomatoes, garlic, and 2 tablespoons olive oil. Season generously with salt, freshly ground black pepper, oregano, and crushed red pepper flakes if using. Toss thoroughly.
03 - Place the block of feta in the center of the baking dish, nestling it among the tomatoes. Drizzle the remaining tablespoon of olive oil over the cheese and season lightly with freshly ground black pepper.
04 - Bake for 25 to 30 minutes until the tomatoes burst and the feta softens with golden edges.
05 - Meanwhile, heat a large skillet over medium heat. Add 1 tablespoon olive oil and the sliced onions. Cook, stirring occasionally, for 15 to 20 minutes until deeply caramelised and golden brown. Reserve.
06 - During onion caramelisation, cook the pasta in a large pot of boiling salted water according to package directions until al dente. Reserve 1/2 cup pasta cooking water and drain.
07 - Once baking is complete, remove the dish from the oven. Add the caramelised onions and chopped basil to the baking dish. Stir thoroughly, breaking up the feta to form a creamy sauce.
08 - Add the cooked pasta to the dish, tossing to coat evenly with sauce. Mix in reserved pasta water gradually to achieve desired consistency.
09 - Portion immediately and garnish with extra basil and a light drizzle of olive oil if desired.