The onion has cells from two sections, one with alinase enzymes and the other with sulfides. When cutting the onion, the previously odorless alinases come into contact with other cells that together produce pyruvic acid and syn-propanotial-S-oxide.
When these substances come into contact with the eyes, they irritate the nerve cells in the eyeball and cause a burning sensation. In reaction to the irritation caused by the onion, the tear glands are activated and release tears that wash the eyes and remove irritating substances. The same acids that are capable of irritating the eyes are the same ones that give the bulb flavor and aroma.
There are countless tips to cut onions and not suffer from the release of gases that irritate the eyes, among them, cut the onions under water, put them in the refrigerator before being cut, fill the mouth with water to cut it, breathe through the mouth when cutting the onions among others.