@ventlio/tanstack-query 0.2.59 → 0.2.61

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -220,15 +220,8 @@ async function makeRequest({ body, method = HttpMethod.GET, path, isFormData, he
220
220
  delete headers['Content-Type'];
221
221
  }
222
222
  try {
223
- console.log({ axiosInstance });
224
- const axios = axiosInstance({ baseURL, headers, timeout });
225
- console.log({ axios });
226
223
  // send request
227
- const resp = await axios({
228
- url: path,
229
- method,
230
- data: body,
231
- });
224
+ const resp = await axios({ baseURL, timeout, headers, method, url: path, data: body });
232
225
  // get response json
233
226
  const jsonResp = await resp.data;
234
227
  // get response code
@@ -1 +1 @@
1
- {"version":3,"file":"index.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"index.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- var axiosInstance = require('./axios-instance.js');
3
+ var axios = require('axios');
4
4
  var buildFormData = require('./buildFormData.js');
5
5
  var request_enum = require('./request.enum.js');
6
6
  var transformer = require('./transformer.js');
@@ -16,15 +16,8 @@ async function makeRequest({ body, method = request_enum.HttpMethod.GET, path, i
16
16
  delete headers['Content-Type'];
17
17
  }
18
18
  try {
19
- console.log({ axiosInstance: axiosInstance.axiosInstance });
20
- const axios = axiosInstance.axiosInstance({ baseURL, headers, timeout });
21
- console.log({ axios });
22
19
  // send request
23
- const resp = await axios({
24
- url: path,
25
- method,
26
- data: body,
27
- });
20
+ const resp = await axios({ baseURL, timeout, headers, method, url: path, data: body });
28
21
  // get response json
29
22
  const jsonResp = await resp.data;
30
23
  // get response code
@@ -1 +1 @@
1
- {"version":3,"file":"make-request.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"make-request.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ventlio/tanstack-query",
3
- "version": "0.2.59",
3
+ "version": "0.2.61",
4
4
  "license": "MIT",
5
5
  "main": "dist/index.js",
6
6
  "contributors": [
@@ -1,5 +1,4 @@
1
- import { axiosInstance } from './axios-instance';
2
-
1
+ import axios from 'axios';
3
2
  import { buildFormData } from './buildFormData';
4
3
  import { ContentType, HttpMethod } from './request.enum';
5
4
  import type { IMakeRequest } from './request.interface';
@@ -25,18 +24,8 @@ export async function makeRequest<TResponse>({
25
24
  }
26
25
 
27
26
  try {
28
- console.log({ axiosInstance });
29
-
30
- const axios = axiosInstance({ baseURL, headers, timeout });
31
-
32
- console.log({ axios });
33
-
34
27
  // send request
35
- const resp = await axios({
36
- url: path,
37
- method,
38
- data: body,
39
- });
28
+ const resp = await axios({ baseURL, timeout, headers, method, url: path, data: body });
40
29
 
41
30
  // get response json
42
31
  const jsonResp: any = await resp.data;