In a large pot over medium heat, add the butter and melt. Add the diced onion to the melted butter and cook until translucent about 5 minutes. (I used my Le Creuset 5 quart Braiser for this whole recipe, even put it in the oven.)
Add the flour. Stir and cook for about 1 minute.
Whisk in the chicken broth and milk and slowly bring to a boil. Reduce heat to simmer and simmer until the mixture thickens slightly. This will take 4 to 5 minutes. Whisk frequently.
Casserole
Remove your pan from the heat and stir in the cheese. Stir until the cheese melts.
Add the sour cream, salt, pepper, thyme, and garlic. Stir until combined.
Fold in the thawed hash browns and stir until combined.
If the mixture isn't in an oven-safe pan, spread the mixture into a 9 x 13-inch baking dish that's been sprayed with non-stick spray.
Combine the topping ingredients and sprinkle over the potatoes. Bake at 375°F for 30 minutes, or until hot and bubbly.