Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

380
Views
TypeError: el argumento "original" debe ser del tipo Función en la aplicación Vue.js

Estoy tratando de llamar a un servicio web de jabón usando el módulo 'jabón' en mi Vue SPA, pero recibo este error solo al importar el módulo. Ya busqué mucho pero no encontré una solución.

Mi código:

 // /src/services/soapService.js import soap from 'soap'; var soapService = { users: { getAllUsers() { const url = 'http://127.0.0.2:8000/?wsdl' soap.createClient(url, function(err, client) { client.getAllUsers(function(err, result) { console.log(result); }) }) } } } export default soapService;

Luego llamo a mi función en un componente Vue:

 <template> <div></div> </template> <script> import soapApi from '@/services/soapService' export default { name: 'Users', methods: { getAllUsers() { this.allUsers = soapApi.users.getAllUsers(); } }, mounted() { this.getAllUsers(); } } </script>

Cuando intento cargar el componente Users.vue, aparece este error:

 TypeError: The "original" argument must be of type Function at promisify (util.js?3022:602) at eval (index.js?4f62:7) at Object.../node_modules/get-stream/index.js (0.js:529) at __webpack_require__ (app.js:854) at fn (app.js:151) at eval (client.js?e3c8:24) at Object.../node_modules/soap/lib/client.js (0.js:586) at __webpack_require__ (app.js:854) at fn (app.js:151) at Object.eval (soap.js?3fc0:19) abort @ vue-router.esm.js?8c4f:2316 eval @ vue-router.esm.js?8c4f:2369 eval @ vue-router.esm.js?8c4f:2138 eval @ vue-router.esm.js?8c4f:2203 Promise.then (async) eval @ vue-router.esm.js?8c4f:2150 eval @ vue-router.esm.js?8c4f:2171 eval @ vue-router.esm.js?8c4f:2171 flatMapComponents @ vue-router.esm.js?8c4f:2170 eval @ vue-router.esm.js?8c4f:2106 iterator @ vue-router.esm.js?8c4f:2362 step @ vue-router.esm.js?8c4f:2004 step @ vue-router.esm.js?8c4f:2008 step @ vue-router.esm.js?8c4f:2008 step @ vue-router.esm.js?8c4f:2008 runQueue @ vue-router.esm.js?8c4f:2012 confirmTransition @ vue-router.esm.js?8c4f:2392 transitionTo @ vue-router.esm.js?8c4f:2260 push @ vue-router.esm.js?8c4f:2715 push @ vue-router.esm.js?8c4f:3037 handler @ vue-router.esm.js?8c4f:1139 invokeWithErrorHandling @ vue.runtime.esm.js?2b0e:1863 invoker @ vue.runtime.esm.js?2b0e:2188 original._wrapper @ vue.runtime.esm.js?2b0e:6961

Nodo v16.11.1 npm v8.1.3 vue v2.6.11

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

Probar:

 import {createClient} from 'soap';
about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!