-
Notifications
You must be signed in to change notification settings - Fork 50
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error when import the package #30
Comments
Hi @mghifariy I think this is an issue for the core repo, probably related to sweetalert2/sweetalert2#1062 which is in sweetalert2 v7.19.1 .. Try upgrading and if it's still malfunctioning open an issue in the sweetalert2 repo |
I'm not sure that
when doing sweetalert2/sweetalert2#1062 is related only to Just to confirm, @mghifariy do you still have that issue after upgrading to v7.19.1? |
@limonte I'm not sure if I installed it correctly. I want to use this package for react native app. Is the installation and usage same as web? In this repo you just give an example code |
@mghifariy sorry about that, this repo is relatively young and we didn't yet add the installation guide. The installation is: npm install --save sweetalert2 sweetalert2-react-content I added the corresponding PR: #31 |
Seems like we're still confusing this package and the core sweetalert2 package. The problem according to the original issue is that importing @mghifariy I can tell you that any library that interacts with the dom, like sweetalert2, will not work in react native because there there is no dom there. If you want to be able to use everything from the web in your mobile app you should read about phonegap but be aware that the User eXperience is not the same as a true native mobile app that uses the native UI like React Native does. Still the error is unexpected and concerning, and we would greatly appreciate some more details on the environment where this error happens.. would you be able to share a repo or a codepen or codesandbox @mghifariy ? Either here or in a new issue in the sweetalert2 repo? |
I am just do
import Swal from 'sweetalert2';
and there's error with this message:
so what happens?
The text was updated successfully, but these errors were encountered: