src/Request.php
public function ip(): string
    {
        $ip = $this->rawIp();

        $parts = explode(',', $ip);
        if ($parts) {
            return $parts[0];
        }
        return $ip;
    }
public function ip(): string
    {
        $ip = $this->rawIp();

        $parts = explode(',', $ip);
        if ($parts) {
            return $parts[0];
        }
        return $ip;
    }
获取用户IP,如果通过CDN,也能获取到
@return string