Some iPhone X units may have a hardware defect causing a green line to appear on its display. A number of owners have reported the issue already, with some referring to it as the "green line of death." Apple hasn't commented on the reports, so it's unknown if this could be fixed with a software update like some of the phone's other early problems.
The top piece of speculation from sites like TechCrunch is that the phone's new sub-pixel pattern and an electrical issue are to blame. That pattern places green sub-pixels in lines, while red and blue alternate. It's possible there's an electrical issue causing the activation of the green sub-pixels in a line.