Proyectos de Subversion LeadersLinked - Antes de SPA

Rev

Rev 208 | Rev 211 | Ir a la última revisión | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 208 Rev 209
Línea 30... Línea 30...
30
        }
30
        }
31
  });
31
  });
32
}
32
}
33
axios.interceptors.request.use(
33
axios.interceptors.request.use(
34
  async (config) => {
34
  async (config) => {
35
    if (
35
    // if (
36
      config.method === "post" ||
36
    //   config.method === "post" ||
37
      config.method === "put" ||
37
    //   config.method === "put" ||
38
      config.method === "delete"||
38
    //   config.method === "delete"||
39
      config.method === "get"
39
    //   config.method === "get"
40
    ) {
40
    // ) {
-
 
41
    // }
41
      const csrf = await Axios.get('/example');
42
    const csrf = await axios.get('/example');
42
      console.log('>>: csrf > ', csrf);
43
    console.log('>>: csrf > ', csrf);
43
    }
-
 
44
    return config;
44
    return config;
45
  },
45
  },
46
  (error) => {
46
  (error) => {
47
    return Promise.reject(error);
47
    return Promise.reject(error);
48
  }
48
  }