-다가 breaks off what you were doing and 자다 is sleeping, so this names what you were up to right before bed: working, watching something, eating, one thought chaining into the next until you drop off. It can also mean falling asleep in the middle of it, which is the joke in the line about nodding off while eating.