export  const arr2Obj = function (data, keyName, valueName) {
  return Object.fromEntries(
    data.map((item) => [item[keyName], item[valueName]])
  );
};

export const initParams = (params) =>{

  return arr2Obj(params, "key", "value")

}
