Enabled grid for 2d animation
You can enable drawing guides and snapping in the Speed Guides Menu.


Check the small icon to enable it
Select the type of guides
Enable snapping and adjust the snapping grid size




You can also enable overlay grid in Viewport Overlay > Canvas and change it's appearance in Viewport Display > Canvas



Further reading in Blender Manual:


Introduction to drawing
Draw Guides
Drawing Planes