When BGP routes are aggregated with the as-match or as-set CLI option, all the component route's extended community attributes are aggregated and the resulting aggregated extended community attributes are attached to the aggregate network.
Aggregation of several extended community attributes is simply the set union of all the extended communities from all of the aggregated routes.