Closed v1ra1 closed 2 years ago
import { CreditCardInput, SquarePaymentsForm } from 'react-square-web-payments-sdk';
This is what fixed it.
I tried the mentioned solution to resolve, with the copied and pasted code into my react project, but still get an error.
Attempted import error: 'payments' is not exported from '@square/web-sdk' (imported as '$6CgYg$payments').
I tried the mentioned solution to resolve, with the copied and pasted code into my react project, but still get an error.
Attempted import error: 'payments' is not exported from '@square/web-sdk' (imported as '$6CgYg$payments').
I am facing the same issue, anyone knows how to resolve this?
We will be looking into this issue, but please create a new one with that error
cc @gabrielelpidio
What version of React are you using?
17.02
What version of Node.js are you using?
16.13.0
What browser are you using?
97
What operating system are you using?
Windows 10
How are you deploying your application?
yarn start
Describe the Bug
import SquarePaymentsForm, { CreditCardInput } from 'react-square-web-payments-sdk';
Using:
`<SquarePaymentsForm /**
In a component.
Result:
Attempted import error: 'react-square-web-payments-sdk' does not contain a default export (imported as 'SquarePaymentsForm').
Expected Behavior
It to load the square form or have a default export?
To Reproduce
Just load it in on a standard react project.