You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
import { toXML } from 'jstoxml'
^^^^^
SyntaxError: The requested module 'jstoxml' does not provide an export named 'toXML'
Workaround
Use:
importtransformfrom'jstoxml'transform.toXML(…)
From the source code in the installed module, I don’t understand why this doesn’t work but the main in the package.json file doesn’t point to the source file but to the built file in dist and whatever transformations are done to generate the file may be where the problem is.
PS. Thanks for making and sharing this :)
The text was updated successfully, but these errors were encountered:
In Node (latest LTS):
Results in the following error:
Workaround
Use:
From the source code in the installed module, I don’t understand why this doesn’t work but the main in the package.json file doesn’t point to the source file but to the built file in dist and whatever transformations are done to generate the file may be where the problem is.
PS. Thanks for making and sharing this :)
The text was updated successfully, but these errors were encountered: