If she doesn't want to be in a relationship with him, she needs to break up with him.
Unfortunately sickness does happen, it is a part of life and you can't shield her from that.
My son was diagnosed with cancer at age 5. Some parents refused to allow their children to contact him, maybe like you, trying to protect their children from the horrors of his little skinny body and his little bald head, of knowing that illness exists and that anyone could get sick. This broke my heart as he was still the same person.
Cancer isn't catching, but it is a part of life for many, many people.
The mam of my son's best friend was amazing, i will never forget that she invited him to his friend's birthday and made a huge effort for it to be safe for him (infection risks etc). This was a lovely, normal experience for him at a terrible time. The kids didn't care, they just accepted he looked different, they had no prejudices. He recovered years ago but still age 10 is best friends with this child.
Most childhood cancers are treatable so the chances are your daughter's boyfriend will recover and lead a long life. How will she feel if she blanked him at the most difficult time of his life? Will the relationship survive that? If she wants the relationship (maybe she doesn't which is fine), she needs to address these questions. If she doesn't want the relationship, she needs to take appropriate steps to end it. Yes these are big questions and hard for a 15 year old (hard for adults too) but they are real and you can't take them away or cope with them by ignoring them.
Remember around half of all people will develop cancer in their lifetime. I guess ask yourself how you would feel if (when?) it is yourself or your daughter getting that diagnosis and suddenly people close to you refuse to contact you, treat you like a leper, are disgusted by your body, don't care how much you are suffering, point out that it must be your fault for eating the wrong food or whatever their instinctive emotional reaction is to your illness.
Personally I came to the conclusion that people do this to spare themselves the pain of knowing this could be them with the serious illness. Unfortunately, it can and statistically WILL be you or someone in your family in that position one day, so do bear this in mind when thinking how to react.