Reputation: 1306
I am using strong-soap package in application. I am facing following syntax issue while translating require() to import statement.
var soap = require('strong-soap').soap;
to
import soap from 'strong-soap.soap' // doesn't work also throwing syntax error
import soap from 'strong-soap';//not working as expected
Your help is appreciated
Upvotes: 2
Views: 1262
Reputation: 11297
soap is an object of strong-soap
so the following would work -- ES6 modules importing.
import { soap } from 'strong-soap';
Upvotes: 7