I don't know what you mean when you say you "assume this is true for instants and sorceries," but you can indeed Disperse your planeswalker to save it from an attack.
Though you'd think, unless they were lower than their starting loyalty, that you'd be better off dispersing the attacker than the planeswalker.
But Epochalyptik I assume his issue is being unsure whether he can disperse in response to attackers being declared the same way he can disperse in response to someone casing lightning bolt.
IE: The question is more one of when he gets priority in combat.
Players must pass priority in succession before the game can advance to the next step or phase. You can cast Disperse in either the declare attackers step or the declare blockers step, but each time you must wait until the turn-based action of assigning attackers/blockers.
I mean for instants and sorceries disperse would be on top of the stack so it would resolve first. However after they assign all their attackers and i assign no blockers and all their attackers are declared at a single planeswalker would i have priority to cast disperse?