Not as a share link, but you can do effectively that with the github authoring if you create a private repo: https://makecode.com/extensions/github-authoring
When you do that, it will automatically create a github pages site for you; e.g. github.com/jwunderl/pxt-fireworks is one example repo I’ve made, and when you push a release it builds a site like this one: https://jwunderl.github.io/pxt-fireworks/ . If the repo is private, it will still make the site, but the students will not have access to the repo itself / the source code.