Both are not comparable as the stickiness dynamics are completely different.
On Twitter, it's mostly the networking effect, you want to be where peoples are, and unless a large chunk move at once, you are stuck there.
On Github, it's the technical cost of migrating, the git part is trivial, but tickets, PR history and CI/Integration are another can of worms.
Projects which moved away, moved away for good, at most only leaving a synchronized mirror.