Heat oven to 400°F. Butter the sides and bottom of an 8-by-8-inch pan or similar baking dish.
In a small saucepot, melt butter over medium-low heat. When butter has stopped foaming, add garlic, and cook until fragrant, about 30 seconds. Add cream, and stir until it starts to steam but does not boil. Add grated cheddar one small handful at a time, stirring constantly as the cheddar melts. Season with salt and pepper as needed, and remove pan from heat.
Toss the potatoes, celeriac, and onion with salt and pepper. Spread seasoned vegetables evenly over the bottom of the baking dish. Pour cheddar sauce over the vegetables, and gently shake the dish to distribute the sauce. Grate any leftover cheddar on top.
Bake for 40 to 50 minutes, until a fork easily pierces the celeriac. Remove from the oven and allow to sit for 5 minutes, until the sauce has thickened slightly. Sprinkle with chopped parsley and serve.