Add 1 tbsp butter and oil to a large non-stick pan over medium heat. Add the onions and fry until they begin to soften and just about start to take on colour (around 15 minutes or so). Season with salt and pepper, then turn the heat to low and continue gently frying until very soft, deep golden and a little sticky (around 30-40 minutes). With a few minutes to go, stir in the garlic and thyme. The lower and slower you fry the onions the softer/more caramelized they'll be, so don't rush the process.
With around 15 minutes to go, add the stock to a medium-sized pot over medium heat. Stir in the Worcestershire sauce and Oxo cubes. In a small bowl or pot to one side, mix the cornflour with 1 tbsp cold water then whisk that into the stock. Gently simmer the stock for 15 minutes until it starts to thicken (you should be left with 450ml liquid).
During this time, peel and very thinly slice the potatoes (approx 1/8"). Grease the base of the baking dish with 1/2 tbsp butter and dice the rest into tiny cubes. Preheat the oven to 170C/340F.
Layer 1/5 of the potatoes in the dish, overlapping slightly as needed to prevent gaps. Season with a pinch of salt, then top with 1/4 of the onions. Drizzle over 1/5 of the stock, then repeat with the remaining layers (remember to season each layer - see notes). Finish with a drizzle of stock then scatter over the butter.
Bake uncovered in the oven for 70 minutes, or until knife tender right the way through. Top with gruyere then finish under the grill until deep golden and bubbly. Rest for 5-10 minutes to allow the potatoes to finish soaking in the stock, then slice into portions, serve up and enjoy!