Preheat the oven to 200°C.
Place a medium saucepan on medium heat and drizzle with oil. Add the onions and allow to soften for 1-2 minutes. Add the rosemary, thyme, capers and garlic, and cook for 3-5 minutes on medium heat, stirring often, until onions are soft. Add the tomatoes, vegetable stock and season with a pinch of sea salt and black pepper. Reduce heat to low and cook, uncovered, for 10-15 minutes. The sauce should thicken and not be watery. Taste and season.
Slice fennel into thin slices (about half a centimeter). Heat a large frypan on medium-high heat and drizzle with olive oil. Working in batches, add the fennel slices to the pan and season with sea salt and black pepper. Cook for 6-8 minutes until slightly caramelized and tender. Repeat until all the fennel has been cooked, adding extra oil if required.
Drizzle a medium baking dish (I used a 30cm oval baking dish) with olive oil and layer your ingredients. Start with a layer of fennel, scatter with some breadcrumbs, spoon over some sauce, dot with mozzarella, sprinkle over some grated pecorino, and season with sea salt and black pepper. Repeat these layers two more times. Drizzle with some olive oil and bake for 30-35 minutes, until the top is golden and the sauce is bubbling up the sides. Remove from oven and allow to sit for 15 minutes.
For the side salad, combine the fronds, salad leaves, lime juice, olive oil and serrano chillies. Season with sea salt and black pepper, and toss gently.
Serve the fennel parmigiana with a side of spicy fennel frond salad.
