Help with our Dapp

hello support,

our DApp is NFT Ticketing android DApp
can buy ticket and Pay using MetaMask wallet in Polygon network.

Because connection to MetaMask from our DApp very slow,
( from opening MetaMask until process of connection )
it takes about 20 seconds.

so, I implement redux into react native now,
after connection, we can send any transaction to the smart contract without need to connect anymore, and just confirm.

but, the problem in here is, when we switch to other mobile application,
and come back to our dapp, to send transaction.
all state in redux become empty ( or back to initial state ).
I implement redux persist with store into async storage,
but failed to send the transaction
because, stringify the big object and parse,
make the object structure become different.

Do you have any suggestion?

MetaMask wallet is great between other wallets available,

but, if the connection to the wallet very slow ( 20 seconds ) and the connection can not stay longer ( after out from the DApp ).
the user experience not good…support.

just, this 2 points very important… for the user…

Our Website

Wow, this work very great…
but, this must be opened in MetaMask Browser

connection very fast,
when buy ticket, confirm also very fast and selection options of gas fee ( no problems at all )

Why we create Mobile DApp?

we hope that easier for anyone to use the DApp, so will get more clients for sure
and Blockchain maybe will become the future of Ticketing System

so, support… , we are very hope…
you can help us to handle this so much important situation…( unfortunately, that we can not handle anymore )

thank you so much MetaMask support
we will wait for your great support…

1 Like

Hello @wahsidin !

Connecting your decentralized application is very slow. This should not happen, you need to determine what exactly slows it down (there are cases of connection slowdown caused by connected react-native-reanimated: ~2.14.4. Also in recent weeks there has been a decrease in performance due to the V8. Then you probably need to rollback to an earlier version: v8-android-jit@11.1000.3 etc…), for a better understanding, you should create an issue on github with a description of your problem and code sections.

Have you figured out why your global state in Redux is being reset?
Have you tried using the React Context API instead of Redux?
Perhaps the problem is in the wrong architecture or somewhere an action is triggered that resets the state of your application. Attach redux code snippets to a github issue.

3 Likes

ok support,
i am using react native version 0.71.3
and the latest is 0.71.8
and test on physical device with android version 9

i already follow and implemented the same steps as your documentation for react
and the proof is… our dapp can connect to your MetaMask wallet

but, the time to open the MetaMask wallet is about 10 seconds
and the process of connect ( that showing the connection icon ) is also takes about 10 seconds

the fact on here is

there should be nothing wrong with react native framework right…
because you all also download and test the same framework… from facebook

My Physical device ( realme C2 - Model RMX1941 )

so, if on your site…there is no problem
is that maybe… my handphone ( or physical device ) has problem?

that’s why i am using opensea on this same device try to connect to MetaMask wallet…wow… is very fast whole process maybe take about a few seconds only

Start with Zero and Empty Framework ( only MetaMask… will it be faster? )

lets say…
if i install the new 0.71.8 react native framework
nothing npm packages inside only MetaMask and react native core packages
( and no… react-native-reanimated )
is connect to MetaMask will be faster?

Android studio - Electric EEL

is android studio have related with this problem also?

Redux Persist can help redux

from this
blog.devgenius…
show that context API same with redux,
only no need to install react-redux’, ‘redux’ and ‘redux-thunk’ libraries.

what we need is when the app is been closed? and reopen again?
the state is still containing the MetaMask sdk …only redux persist offer this by using react async storage

but the problem is too deep of MetaMask sdk object ( when stringify and parse,
it can be saved into react asnyc storage, but the structure become different, so this object can not be used again to confirm the transaction )
so, we still using redux only…

Finally, for making our discuss… hit the point!

what should i use:

  1. What react native framework version?
  2. What physical device ( for example, xiaomi, ovo, vovo,etc )?
  3. What android studio version?
  4. and What version of MetaMask SDK? should compatible with all above conditions!

So, we can see that MetaMask will open so fast…
like opensea open the MetaMask.

like building the website… right…
no website will compatible with all old browsers…
at least we know which latest browser will work best… to open and run the website.

so, we just want to know, What react native? What physical device? What Android-studio? What MetaMask SDK? What Combinations between this all? will make the MetaMask and our DApp work like a charm…

and this can be added to your documentation information…, so we know what to do right…

@wahsidin

You should probably try to get started with integrating MetaMask into a mobile application without additional libraries and dependencies, and go from small to large to identify problems and bottlenecks in your application that slow it down.
For a while I stopped using Redux in applications due to its redundancy, the Context API that comes out of the box in most cases completely satisfies all whims.
The documentation will be updated and expanded soon, you understand that there are no ideal conditions and each case is unique ( library versions / hardware / simulators / environment).
Open an issue on Github and try to describe your problem in detail (as you do here) by attaching code sections that relate to this case.

2 Likes

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.