Difference betwen npm run build, ng build and ionic build

Hey guys, noob here. I have watch tutorials on ionic and angular, and I just can’t differentiate all these 3 as saw different developers used 3 different kinds of command.

  • npm run build
  • ng build
  • ionic build

Can anyone tell me what’s the difference and which one should I actually run for my ionic project?