When Wal-Mart announced first-quarter earnings Thursday, the highlight was a surge in online sales. E-commerce for the retail giant rose 63 percent. Its stock subsequently rose more than 3 percent on the day and set a new high-water mark for its 52-week range.

"Wal-Mart beats on earnings as online sales surge," "Wal-Mart targets Amazon," and "Wal-Mart's e-commerce goes through the roof" read the headlines across news sites.

Somewhat buried in the numbers, but not lost on investors, was also an increase in foot traffic to its stores. At a time when retailers of all types are lamenting lost customers, Wal-Mart bucked the trend and brought more customers into its brick-and-mortar locations.

Meanwhile, Target reported its fourth consecutive quarter of lower sales the day before Wal-Mart's earnings report. Its foot traffic took a step back, though online sales did rise 22 percent.

The two big-box rivals have set out on divergent strategic paths, hoping to find the elusive solution to a disrupted — and some would say doomed — retail environment. Early on, it would appear Wal-Mart is the clear winner. So what is Wal-Mart doing better than everyone else in retail?

In its infancy, e-commerce was widely thought to be the death-knell for traditional retail, but it has become clear that the ultimate survivors will likely share some combination of the two, that an omnichannel approach is key. That's why online giant Amazon last year announced intentions to open physical stores.

Consumers have shown a preference for online research and offline buying. A recent study by Retail Dive found two-thirds of surveyed consumers said they research products online at least occasionally before shopping for them in a store.

And it goes beyond catering to consumer sentiment and habits. CNBC did a study that surprisingly found running an online store doesn't necessarily offer the savings and expected profit margin over operating a physical location.

"Conventional wisdom suggests that running retail stores is more expensive than selling the same merchandise online," the article stated. "Conventional wisdom is wrong."

In a May 2016 Harvard Business Review article, David S. Evans and Richard Schmalensee concluded, "It is becoming increasingly clear that retail reinvention isn't a simple battle to the death between bricks and clicks. It is about devising retail models that work for people who are making increasing use of a growing array of internet-connected tools to change how they search, shop and buy.

"Creative retailers are using the new technologies to innovate just about everything stores do from managing inventory, to marketing, to getting paid."

That brings us back to Wal-Mart, which has made no secret of its intentions to take on Amazon. The discount chain has levied significant investments into bulking up its online prowess, such as the acquisition of Jet.com.

Target, on the other hand, laid out a plan to lean more heavily on its stores, embarking on a process to overhaul as many as 100 locations and open more than two dozen smaller-format stores.

Perhaps the million or more appropriately, billion dollar question for Target then becomes what does today's (and tomorrow's) consumer want in a store? The experiments are many and ongoing. Quartz recently examined some of the concepts coming from retail's most forward thinkers, but necessarily points out, "It remains to be seen which — if any — of these concepts will catch on and endure."

The majority of purchases still happen in stores, of course, and Target has about 1,800 of them. If Target can get the stores correct, perhaps it wins in the long run. Right now, thanks to its online success, most analysts are betting on Wal-Mart, which is commonly seen as a less inviting and engaging in-store shopping experience than Target stores.

Wal-Mart and Target keenly acknowledge omnichannel is the way, but it's the proper mix that will prevail in the end. The stakes are high for getting it right. The partial casualty list for this year alone in retail includes Rue 21, which just filed for Chapter 11 bankruptcy protection, Sears, Kmart, Macy's, JC Penney and Abercrombie & Fitch all which have announced store closings.

Wal-Mart's ability to increase foot traffic was likely at least partially due to heavy discounting in pricing, which caused average customer tickets to decline slightly. Its ability to discount can only carry it so far, though, and competition in food markets from discount grocers like Aldi remains a threat.

So while the news was certainly positive for Wal-Mart this week, it realistically falls short of the Business Insider headline, "Wal-Mart just proved it's immune to the retail apocalypse." Wall Street has little sympathy for poor quarterly performances, and if retail has shown anything over the past few years, it's that success is anything but assured.