Before Tuesday’s primaries, the media buzzed about the risk of Democrats getting locked out of seats thanks to California’s primary system, in which the top two candidates, regardless of party, go on to the general election. In New Jersey, commentators mused that Democrats might throw away pickup opportunities by nominating super-progressive candidates rather than moderates who fit well with suburban districts. Neither of those worries panned out. Instead, Democrats remained poised to boot out Republicans who have not been able to unshackle themselves from President Trump.

In New Jersey, conservative Democrat Jeff Van Drew beat out progressive activist Tanzie Youngblood in the 2nd Congressional District primary. Van Drew, in a district Trump carried by less than five points, has a solid chance to win a seat left open by retiring Rep. Frank LoBiondo (R-N.J.). This is a seat Democrats normally wouldn’t expect to win; in the era of Trump, it’s a solid opportunity.

In the Democratic primary in New Jersey’s 7th district, former State Department official and human rights expert Tom Malinowski, regarded as an affable moderate, will face incumbent Rep. Leonard Lance (R-N.J.), who normally would be a prohibitive favorite. However, in a district narrowly won by Hillary Clinton in 2016, Democratic turnout topped Republican turnout by nearly 6,000 votes; it is the sort of seat that could flip in a wave election.

The NJ-11 was the most interesting contest. Rep. Rodney Frelinghuysen (R-N.J.) is retiring, providing another Democratic opportunity. Charismatic moderate Mikie Sherrill, a Naval Academy graduate with an impressive 10-year military career followed by a few years in the U.S. attorney’s office, got the backing of party regulars (not to mention former vice president Joe Biden). Watch for her, like former pilot Amy McGrath, who won the Democratic nomination in Kentucky’s 6th Congressional District, to be a breakout star for Democrats. Sherrill beat out the more left-leaning Tamara Harris. The Cook Political Report’s David Wasserman tweeted, “Sherrill [is] probably a slight favorite. This district is moving away from Rs in a hurry.” He added, “It’s quite possible Republicans will have zero federal officeholders from North Jersey post-2018. [I] can’t remember a time that was the case.”

In California, Democrats can breathe a sigh of relief knowing that they were not shut out of a single key congressional race. In the 10th, 25th, 39th, 45th, 48th and 49th districts, Democrats will have competitive candidates in districts all won by Hillary Clinton. Katie Hill in the 25th and Katie Porter in the 45th were two of the many Democratic women to win on Tuesday. The 25th might normally be a tossup, but Hill likely has an edge in the current #MeToo, anti-Trump political climate.

To top it off, another state legislative seat flipped from R to D, the 42nd this election cycle, thanks to Democrat Lauren Arthur’s win in the Kansas City suburbs. The Post reported that “Arthur defeated Republican Kevin Corlew — a fellow state legislator — by 19 points. That represented a sizable swing toward Democrats in the 17th district, which backed both Donald Trump and Mitt Romney by 4 points. . . . . While Republicans have flipped several seats in more conservative areas, Democrats have seen a surge in suburban districts. Last month, they gained a historically Republican district in Pennsylvania’s Bucks County while Republicans flipped a Democratic seat in a rural district south of Pittsburgh.”

In New Mexico, Deb Haaland prevailed in the Democratic primary in the 1st district, hoping to be the first Native American woman in Congress.

Finally, in Iowa, two women won Democratic primaries in key races. Cindy Axne won in the 3rd district. In Iowa’s 1st district, considered a tossup seat, Democrat Abby Finkenauer, a state representative, will face off against Rep. Rod Blum, who some prognosticators say is the most vulnerable Republican in the country.

Democrats should be cautiously optimistic about Tuesday’s results. If they carry the House in November, much of the heavy lifting will be done by a slew of female candidates, many of whom are political newcomers.