While many retailers have struggled mightily, or even gone out of business, a few have bucked that trend.

The companies defying current industry logic do things differently. They haven't been hurt by the internet because they offer consumers experiences and opportunities that can't be easily replaced by digital offerings.

In addition, all three -- Costco (COST -0.12%), Dollar General (DG -0.36%), and TJX Companies (TJX 1.20%) -- offer value. It's not just about being cheap, but pricing has proven important in a market where consumers can get nearly anything they want with just a few keystrokes.

A Dollar General store

Dollar General has grown revenue by adding locations. Image source: Dollar General.

Dollar General keeps growing

Dollar General's growth model has been about adding stores more than growing sales at its existing locations. Basically, the chain has a model that works: It opens in a new area and builds its business to a predictable level. That may not be the typical model investors reward, but it's a successful and sustainable one.

In Q1 2017, Dollar General saw overall sales rise 6.5% to 5.6 billion, driven mostly by the addition of new stores. Same-store sales rose 0.7% for the quarter, which the company attributed to "an increase in average transaction amount, partially offset by a decline in traffic."

The chain expects to add 1,290 new stores in 2017, after adding about 1,000 in 2016. That will continue to drive revenue higher as the company has proven it knows how to identify markets for efficient growth.

Consumers love hunting for bargains

The TJX Companies brands, which include Marshalls, HomeGoods, and T.J. Maxx, all share one trait in common: The three discount retailers carry ever-changing merchandise. That allows bargain-seeking customers to have a sense of discovery when they find something they want. It also drives repeat visits because you never know when you'll find the deal you were looking for (or that you didn't even know you wanted).

During the first quarter of the company's fiscal 2018, TJX saw net sales rise by 3.8% to $7.8 billion. In addition, comparable-store sales grew by 1%.

"Earnings per share were $0.82 and above our plan," said CEO Ernie Herrman in the earnings release. "Comp store sales growth was once again driven by customer traffic. We achieved these results despite the unfavorable weather in parts of the U.S. and Canada compared to last year."

The CEO also noted that sales trends improved later in the quarter. TJX expects diluted earnings per share in the range of $3.82 to $3.89, a 10% to 12% increase over the prior year's $3.46.

Costco has been a model of consistency

As a membership-based warehouse club, Costco is not dependent upon same-store sales. Instead, the company makes most of its money (about 75%) from selling memberships. That means the chain does not have to convince customers to buy more, it merely needs to give them enough reason to renew their memberships.

Costco, which just slightly raised its membership prices, hovers around a 90% renewal rate while steadily adding members. The total number of people holding Gold Star, Business, and Executive memberships rose again in Q2 2017, according to CFO Richard Galanti.

"Total card holders, [were] 88.1 million at second quarter end, up from 87.3 million 12 weeks earlier," said Galanti, according to Seeking Alpha's transcript of the call (registration required).

Costco has a model that offers both value and destination shopping. The company has cheap prices for groceries, household items, and everything from gas to electronics. It also has a changing array of merchandise as well as product samples, and a food court that keep members coming back. That has proven to be an internet-proof formula that should remain so even as digital shopping becomes even more dominant.