You can but it would be advisable to try to look for jobs before you visit Canada to line up some interviews to avoid wasting any time. The employer needs to get a labour market opinion for you to be able to apply for a work permit. This process can take anywhere from a few weeks to a few months. If you do get the work permit, it is usually for at least a year, sometimes two. When it is about to expire, you and your employer can apply to extend.
The advantages of a work permit over applying for PR directly is that you get to Canada faster and you can always apply for PR later. The disadvantages is that you are tied to one employer. You can not take a side job if you need money. If you get laid off, you will need a new LMO and a new work permit to be able to take another job.