Recession fears have sent the Nasdaq Composite plunging into a bear market. The tech-heavy index is currently 31% off its high, marking its sharpest decline in the past decade. Losses of that magnitude can rattle even the most experienced investors, but there is a silver lining to that historic bear market: The Nasdaq has recovered from every past downturn, and there is no reason to believe this one is any different.

With that in mind, the current situation is a once-in-a-decade buying opportunity for patient investors, and excellent stocks like The Trade Desk (TTD 1.61%) and Netflix (NFLX 1.46%) are trading at attractive valuations.

The Trade Desk: A leader in advertising technology

The Trade Desk is an ad tech company. Its demand side platform (DSP) automates the ad buying process, enabling marketers to create and optimize data-driven campaigns across digital channels like desktop, mobile, and connected TV. Despite tough competition, The Trade Desk has distinguished itself through product innovation and a reputation for transparency.

At the heart of its DSP is an industry-leading artificial intelligence engine and an unmatched data marketplace, both of which improve campaign performance by helping marketers target the right consumers with the right ads. Additionally, The Trade Desk operates an independent DSP, meaning the company does not own any web content, and therefore has no bias toward any specific ad inventory. Meanwhile, Meta Platforms and Alphabet have a clear incentive to favor their own inventory -- think Facebook, Instagram, Google Search, and YouTube.

In a nutshell, those ad giants are challenged by conflicts of interest, and that has helped The Trade Desk gain market share. In the third quarter, revenue rose 31% to $395 million and non-GAAP earnings soared 44% to $0.26 per diluted share. Those results are particularly impressive because other ad-based businesses have struggled amid the uncertain economic climate. In fact, CEO Jeff Green said The Trade Desk gained more market share in the third quarter than at any point in its history.

Looking ahead, investors have good reason to believe that momentum will continue. Global digital ad spend is expected to increase at 10% annually to reach $876 billion by 2026, according to eMarketer, and The Trade Desk has distinguished itself as the leading independent DSP.

With that in mind, shares trade at 16.2 times sales today, a notable discount to the five-year average of 23.9 times sales. That's why patient investors should buy this growth stock.

Netflix: The king of binge-worthy content

Netflix topped Wall Street's consensus in the third quarter, but many investors are still worried. The company lost subscribers in the first and second quarters, and it only grew its subscriber base 5% to 223 million in the third quarter. As a result, revenue rose just 6% to $7.9 billion, and management expects top-line growth to decelerate further in the fourth quarter.

That said, the situation is less dire than it appears. Netflix is struggling with several headwinds that will ultimately be temporary. High inflation has caused consumers to cut back on spending, and the strong U.S. dollar has created unfavorable foreign exchange rates. For instance, third-quarter revenue increased 13% in constant currency. However, in spite of those headwinds, the company still generated positive free cash flow of $472 million in the third quarter, a big improvement from a loss of $106 million in the same period last year.

Better yet, Netflix is executing on a strong growth strategy. It recently debuted a cheaper ad-supported streaming service, and management says that product "will lead to a significant incremental revenue and profit stream." The company also plans to crack down on account sharing next year by requiring users in different households to either create a separate account or add a "sub-account" if they want to pay for additional family and friends.

More broadly, the investment thesis is still very much intact. Streaming is the future of home entertainment, and Netflix is a powerhouse in the streaming industry. It accounted for 7.2% of all streaming time in October, according to Nielsen. For context, that falls short of the 8.5% market share held by Alphabet's YouTube, but it easily beats Walt Disney's 4% and 2% market share with Hulu and Disney+, respectively. It also tops the 2.8% market share held by Amazon Prime Video and the 1.1% market share held by Warner Bros. Discovery's HBO Max.

Moreover, Netflix currently owns eight of the top 10 original streaming programs, and six of the top 10 original streaming movies. In other words, Netflix is producing far more binge-worthy content than its rivals, and that ability to engage viewers has advertisers champing at the bit. For that reason, investors should look for revenue growth to reaccelerate a few quarters down the road.

With that in mind, the stock currently trades at 4 times sales, a bargain compared to the five-year average of 8.5 times sales. That creates a very reasonable buying opportunity.