A budget-friendly creamy tart featuring slow-cooked golden-brown onions, fresh thyme, and homemade shortcrust pastry.