We are talking about the written form of the language, not how it is pronounced. Wikipedia tends to use an experimental written form called LSC as if it was official. On the contrary it has been heavily criticized for representing mainly northern varieties, for taking its written form Italian (for instance "Sardigna" written as such is actually Tuscan, you can find it written this way in Dante) instead of continuing the institutional form of written Sardinian which dates back to the Middle Ages. As explained in the source I posted writing "gue/gui" allows to use "ghe/ghi" to represent different pronunciations from north to south ([g] in the north and [dʒ] in the south. Example: "arghentu". Linguistically speaking if we write "gh" we shouldn't be speaking of "Sardinian" as a whole since it is a written form that doesn't allow representation of the majority of Sardinian speakers since you wouldn't have a way to represent [dʒ] by writing "gh" for both cases. The written form "gh" for "S'Aliguera" could only represent a dialect inside Sardinian that is one language from its southern to its northern varieties since the main differences are in the pronunciation. But even if it could represent a dialect there is no need to use that since both southern and northern dialects can be represented as said before. Let me also point out that different pronunciations for the same graphemes is something common to other languages such as Arabic (particularly on the pronunciation of ج) and Spanish (for the "ll").