Trolling is essentially online pranking. There's good-natured "smile, you're on candid camera" pranks, and then there's just being an asshole.
E.g. I'm pretty sure some people might think that "swatting" is a form of trolling.
That was the OG trolling, you were wasting peoples time for laugh while they were educating you about something.
Term got hijacked and morphed into causing mental trauma to people.
One was harmless prank causing eye rolling, other mental trauma.