The router option is best as it's much less trouble to set up and maintain. Decent hardware routers aren't that expensive any more - Netgear for example have an excellent range (but so do lots of other manufacturers).
It's also possible to share an internet connection through Windows ICS (internet connection sharing) without the use of router or hub - but then the host computer must be on for the second computer to use it, and it can be a major pain to set up, and maintain if something goes wrong. If you can afford the expense, a hardware router is the way to go.