Repl with Custom Domain - Prevent Default Domain from Being Indexed by Search Engines

Let’s say I’ve got an HTML/JS/CSS repl, myrepl.noquinn.repl.co that I’ve linked to some custom domain, customdomain.gov.

I want customdomain.gov to be indexed by search engines, but not myrepl.noquinn.repl.co (bc the url just isn’t as pretty).

How can I do this? Is this something that can be done with a robots.txt file or some setting in Replit or Cloudflare?

Or is this not even an issue that I need to worry about?

You could implement a JavaScript check to see if the domain ends with “repl.co”, and if it does, redirect the page to your custom domain.