How do you punctuate sentence with 'if'?

If should be followed by a dependent clause, a comma, an independent clause and then a period.