I am so sorry to hear of your situation. I hate issues of death and talking to my kids so I sympathize with your uncertainties. As background, three of my grandparents died when I was between 3 and 10, I went to the hospital to visit near the end and to 2 wakes and 2 funerals - and I do remember these. In honesty, it is some of my clearest memories, which may sound sad, but it also makes me feel connected to my grandparents because I remember being sad and missing them.
I think it is very important to let your kids be involved when she passess away. I think participating with the family at the wakes and funerals is very important as a mechanism as closure and to experience their grief in complete way. I am very resentful that I did not attend my one grandparent's funeral and remember very clearly wanting to go.
I think it is up to YOU to make it not confusing. I think you need to send a clear message that not everyone who gets ill, dies. They should not be scared of being sick. However, I think seeing her ill will give them a chance to prepare a bit and acknowledge "something is wrong." I don't think I would tell them she is dying, since that could be scary and anxiety ridden, but I think they should visit with her and make their "goodbyes" even if they don't know it is goodbye. Maybe you can have them make pictures or take photos or do an activity with their grandmother that they will be able to remember as a particularly nice time with her. When she does pass, I think you need to invite them to attend the wake and funeral, and speak honestly to them about your beliefs (heaven, funeral as a cvelebration of life and a way to say goodbye, etc.) and expain in simple terms what to expect at each. Honesty is the best policy in my perspective. If you do all this, and the child doesn't want to go, then I would not force it. But I would encourage it, so they don't regret it.