We have a square metal feeder with a drop down front porch so if a squirrel tries to eat they shut off access to the food by their weight. It’s worked great for 30+ years (we are on our second one). When the squirrels get too plentiful we get out the .22.
We had that kind of feeder for a while. Squirrel managed to get inside and was trapped there ;-)