A hub is okay if you only have a few computers, but with more it's bad. If you use hubs in a network, all the nodes are in 1 big collision domain which creates a lot more frame collisions and therefore slows network performance. With a switch/router, it splits up the collision domains, increasing performance. Hubs also split the bandwidth between each port, with switches you get full bandwidth usage. If you want to share internet, there's no questioning in what you should get -- router.
Anyone please correct me if I'm wrong.