Dollar General (NYSE:DG) had a fantastic fiscal first-quarter (ended May 1). People flocked to the stores, which remained opened with altered operations such as earlier closing times, resulting in same-store sales (comps) jumping 21.7%. Higher sales drove diluted earnings per share (EPS) 73% higher from $1.48 to $2.56, despite higher costs related to COVID-19 such as employee bonuses.

Certainly, the company benefited from shoppers buying more items from Dollar General's consumables category (e.g. paper towels, packaged foods, and personal care products like soap and shampoo).

This is not a long-lasting effect, however. Therefore, with the stock trading close to its 52-week high, does Dollar General still represent an attractive buying opportunity?

A woman with shopping bags in her right hand and a piggy bank in her left hand.

Image source: Getty Images.

Consistent growth

Dollar General has a simple and effective business model. It draws customers to its stores with attractive prices on a variety of goods. These include everyday items like soap and toothpaste, home products such as kitchen supplies, apparel, and seasonal items.

This is working for the company. Last year, Dollar General posted a 3.9% comps increase. Remarkably, this extended its annual streak of positive comps to 30 years. There aren't many retailers that can make that claim.

Over the last five years, it has grown diluted EPS at a compounded annual growth rate of 11%, from $3.96 to $6.64.

With the U.S. economy in a recession, Dollar General will likely do even better. Management noted that many of its customers are on a fixed income or have low wages, and are among the first to feel the impact of an economic downturn.

The consumables category, accounting for 79% of Dollar General's first-quarter sales, puts the company in an enviable position. Even in a recession, people still need to buy paper towels, toilet paper, trash bags, and milk, among other everyday items.

CEO Todd Vasos said on the first-quarter earnings call that the company has experienced higher demand during previous recessions. The comps bear this out: Dollar General's fiscal 2008 comps rose 9%.

Growing dividend

These strong sales and earnings have led to Dollar General producing a healthy amount of free cash flow (FCF) that continues to grow. Last year, its operating cash flow was $2.2 billion. After deducting $785 million for capital expenditures, Dollar General's FCF was $1.5 billion. This easily covered its approximately $328 million of dividends.

The company has used the increasing FCF to reward shareholders by raising dividends annually since it first declared one in 2015. This includes increasing April's payment from $0.32 to $0.36.

In short, the business has produced consistently strong results and has a history of raising dividends. Of course, this is not lost on investors, and the stock, with a trailing price-to-earnings ratio of 25 times, is not cheap. While Dollar General shares are not in the bargain bin, this strong performer deserves a place in your portfolio. Ownership in quality companies sometimes requires paying up a bit.

This article represents the opinion of the writer, who may disagree with the “official” recommendation position of a Motley Fool premium advisory service. We’re motley! Questioning an investing thesis -- even one of our own -- helps us all think critically about investing and make decisions that help us become smarter, happier, and richer.