We investigate theoretically valley-resolved lateral shift of electrons traversing an n–p–n junction bulit on a typical tilted Dirac system (8-Pmmn borophene). A gauge-invariant formula on Goos–Hänchen (GH) shift of transmitted beams is derived, which holds for any anisotropic isoenergy surface. The tilt term brings valley dependence of relative position between the isoenergy surface in n region and that in the p region. Consequently, valley double refraction can occur at the n–p interface. The exiting positions of two valley-polarized beams depend on the incident angle and energy of incident beam and barrier parameters. Their spatial distance D can be enhanced to be ten to a hundred times larger than the barrier width. Due to tilting-induced high anisotropy of the isoenergy surface, D depends strongly on the barrier orientation. It is always zero when the junction is along the tilt direction of Dirac cones. Thus GH effect of transmitted beams in tilted Dirac systems can be utilized to design anisotropic and valley-resolved beam-splitter.