If the author has a minimal reproducible version of what is his issue, then the outside resource link isn't necessary. If the MCVE included in the question doesn't illustrate the problem yet the one in the outside resource does, including the code from the outside resource is warranted, otherwise close it as lacking MCVE.
The later option is obviously more costly for the community so it should be avoided. It can be simply edited into the question, in all the years of SO, I haven't heard of a single case of someone complaining that its code was included in the question so others can answer it... never.