It really depends on the publication’s guidelines. Some publications have a strict ‘only unpublished drafts’ rule so you can’t publish first and submit to them after. Honestly, I’ve never submitted an already published piece to publications. All my submissions are unpublished drafts.