BuzzFeed Inc. is close to a deal to go public through a merger with a special-purpose acquisition company, according to people familiar with the situation, part of a plan to consolidate other players in digital media.