Depending on the thickness of the trim, your door might not be able to clear the molding. If that's the case, we recommend installing a header board to enable smooth sliding. It is also up to you whether you would like the door width to be increased so it will cover the trim as well. Since the track is typically mounted above the trim, you might need to accommodate by increasing the door height as well.