What happened 

Shares of Apple (AAPL 0.69%) rose in early trading today after Bloomberg reported yesterday that the company had shown a new augmented reality (AR) and virtual reality (VR) headset to its board members. But the early gains were quickly erased as investors grew increasingly worried about the economy.

The tech stock gained as much as 2.4% this morning but was down by 2% as of 12:50 p.m. ET. 

So what 

Part of investors' early positive sentiment toward the stock may have come from a Bloomberg report that said the tech giant had shown off an AR/VR headset to its board members recently. Apple showing its board members the device indicates that it could be close to launching the product.

A person looking at charts.

Image source: Getty Images.

Not a lot is known about the device right now, but the headset combines AR and VR and could debut as early as the end of this year and be available to consumers in early 2023.

Apple investors are eager to see such a device launch because it would be the first device in a new segment category since Apple launched its Watch. 

But any optimism about Apple's stock, and stocks in general, quickly faded -- investors are getting increasingly worried about rising inflation and how aggressively the Federal Reserve will respond to it. 

With inflation at a nearly four-decade high, the Fed has already hiked rates twice, with an aggressive 50-basis point hike earlier this month. More interest rate increases are coming this year, and that's spurred investors to leave stocks -- even typically stable tech stocks like Apple -- over the past year.

Investors are worried that the Fed's moves could end up tipping the U.S. into a recession, and those fears are pushing many people out of tech stocks in particular. The tech-heavy Nasdaq Composite was down by 1.8% today as of this writing.

Now what 

In the short term, investors should be prepared for more share-price dips as the Fed tackles inflation. 

But news of Apple's potential device should be a good reminder for long-term investors that even when the market gets choppy, there are still great companies out there that are creating devices and services that could help them grow long after the market volatility has passed.