when markdown is loaded preview is created