@iankibetsh/vue-streamline 1.2.8 → 1.2.9
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/package.json +1 -1
- package/src/composables/useStreamline.js +18 -10
package/package.json
CHANGED
|
@@ -112,17 +112,25 @@ const useStreamline = (stream, ...initialArgs) => {
|
|
|
112
112
|
if(action.includes(':')){
|
|
113
113
|
[newStream, action] = action.split(':')
|
|
114
114
|
}
|
|
115
|
-
const
|
|
115
|
+
const post = {
|
|
116
116
|
action,
|
|
117
|
-
stream:
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
117
|
+
stream:newStream,
|
|
118
|
+
params: args
|
|
119
|
+
}
|
|
120
|
+
return `${streamlineUrl}?${new URLSearchParams(post).toString()}`
|
|
121
|
+
|
|
122
|
+
// // Add each arg as a separate param
|
|
123
|
+
// args.forEach((arg, index) => {
|
|
124
|
+
// let value = arg;
|
|
125
|
+
// if (typeof arg === 'object' && !(arg instanceof Date)) {
|
|
126
|
+
// value = JSON.stringify(arg);
|
|
127
|
+
// } else if (arg instanceof Date) {
|
|
128
|
+
// value = arg.toISOString();
|
|
129
|
+
// }
|
|
130
|
+
// params.append(`params[${index}]`, value);
|
|
131
|
+
// })
|
|
132
|
+
|
|
133
|
+
// return `${streamlineUrl}?${params.toString()}`
|
|
126
134
|
}
|
|
127
135
|
|
|
128
136
|
const service = reactive({})
|