I think there was a nanny backstage as Lucas Tindall who is one-years old only came out at the last minute.
At one point Louis was taken away - I think to get him in a calmer space for the balcony stuff.
That's where Kate was in a different spot than if it had happened to a mother in Tesco, or at a wedding etc. They had a specific end of Jubilee balcony event which they wanted the direct heirs and family at and so whisking Louis off to bed, or risking him working himself up into a tantrum were not an option.
I suspect there was a severe talking to happening before they came out on that balcony. Or some bribing!
I'm pretty sure by the time he's at another public event next year, he'll have matured a bit and will be more like George and Charlotte who at only 9 and 7 were amazingly well behaved all weekend.
But he does give off cheeky 3rd child vibes so maybe he will be the entertaining one for years to come.