When the instance created by axios through create is called, what is the reason why the first parameter of params starts with &?

axios version: 0.18.0 and 0.17.1


// axios
var req = axios.create({
    baseURL: "http://abc.com",
    timeout: 15000
})

// 
req({
    method: "get",
    url: "/node/getList",
    params: {
        a: "a"
     }
})

// 
// http://abc.com/?a=a

//  
//http://abc.com/&a=a

but instances created directly through axios do not have this problem

// 
import axios from "axios"
axios({
    method: "get",
    url: "abc.com"
    params: {
        a: "a"
    }
})

what is the reason for this?

Mar.03,2021

  1. ? separates the actual URL and parameters;
  2. & is the delimiter between parameters specified in URL;
  3. is parsed to &, which should default to the parameter
  4. preceding a _
Menu