Yes, buy why?I wouldn't have given the place a second glance until a video popped up in my YouTube feed, something like "eating for a week from Dollar Tree on $10."
Now it's not exactly a Mormon cannery, you likely won't find a TON of things to put back for long term. But my local one had a surprisingly good selection. Rice, beans, lentils, spices, jelly, sauces, etc.
They even have cold foods. It's not a one stop prep food shop, but there are options there while also potentially stretching your money further in these times of shortages and high prices. Just do your homework, there are cases where you might be paying more there than you would be getting a bigger package elsewhere.
I'm intrigued to try the dollar box of instant oatmeal I got there. Apple cinnamon, they also had plain. And while some of their items are only able to be sold for $1 because of a small package size - this is a full 6, 43 gram, 160 calorie servings, just like the Quaker I had at home.
Compare DT with WM prices and I think WM would win.