A delightful twist on the classic tamale bake, this casserole combines pinto beans, corn, and cheese in a flavorful and easy-to-make dish.
Preheat your oven to 350°F and grease a 9x13 inch baking dish.
Greasing the dish ensures the casserole doesn't stick and makes cleanup easier.
In a medium saucepan, sauté the chopped onion and minced garlic in a bit of oil until softened.
Cook over medium heat to avoid burning the garlic, which can turn bitter.
Add the diced green chilies, tomato sauce, and pinto beans to the saucepan. Stir and let simmer for 10 minutes.
Stir occasionally to prevent sticking and ensure even cooking.
In a mixing bowl, combine the cornmeal, flour, baking powder, milk, and egg to form a batter.
Whisk until the batter is smooth and free of lumps for an even texture.
Pour half of the batter into the prepared baking dish, spreading it evenly.
Use a spatula to spread the batter evenly for a uniform base.
Spoon the filling mixture over the batter, spreading it out evenly.
Ensure the filling covers the batter completely for balanced layers.
Sprinkle the corn kernels over the filling, followed by half of the shredded cheeses.
Distribute the cheese evenly for consistent flavor in every bite.
Pour the remaining batter over the top, drizzling it to create a lattice-like pattern.
Drizzle carefully to allow some filling to peek through for a rustic look.
Bake in the preheated oven for 35 minutes, or until the top is golden and springs back when touched.
Check for doneness by inserting a toothpick into the batter; it should come out clean.
Let the casserole cool for 15 minutes before serving to allow it to set.
Cooling helps the layers firm up, making it easier to slice and serve.