Whisk 1 cup all-purpose flour and 1 cup whole milk in a saucepan, then cook over medium heat for 5 to 7 minutes, stirring constantly, until thick like pudding.
Cool the cooked mixture completely, then beat 1 cup unsalted butter, softened, and 1 cup granulated sugar until fluffy.
Beat in 2 tsp vanilla extract and a Pinch of salt, then add the cooled flour mixture one spoonful at a time.
Beat on medium-high speed for 5 to 8 minutes until smooth and fluffy, then spread or pipe onto completely cooled desserts.