SafeEventEmitterProvider for react Jsx format #1383
Replies: 14 comments 6 replies
-
Can you share your compilation logs? And also your code related to it? |
Beta Was this translation helpful? Give feedback.
-
Hi Prachi and Sandip
can you pls share those logs with the Web3 provider pls.
thanks
Sundeep
…On Mon, 27 Feb 2023 at 17:01, Yashovardhan Agrawal ***@***.***> wrote:
Can you share your compilation logs? And also your code related to it?
—
Reply to this email directly, view it on GitHub
<#1383 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AFOYNUOHZNVVKCBQBOIQ7MTWZQ7L5ANCNFSM6AAAAAAVI5RJQ4>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
Beta Was this translation helpful? Give feedback.
-
thanks
Sundeep
…On Mon, 27 Feb 2023 at 18:39, sandippa26 ***@***.***> wrote:
okay @sundeep138 <https://github.com/sundeep138>
—
Reply to this email directly, view it on GitHub
<#1383 (reply in thread)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AFOYNUIMTSS2DOW5DHWR5MLWZRK27ANCNFSM6AAAAAAVI5RJQ4>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
Beta Was this translation helpful? Give feedback.
-
Thanks Sandip.
Web3 team pls let us know what are we missing to make web3 modal work.
Thanks
Sundeep
…On Mon, 27 Feb 2023, 1:14 pm sandippa26, ***@***.***> wrote:
Hello @yashovardhan <https://github.com/yashovardhan> i'm facing an issue
when using web3auth and auth0 it will give error "WalletLoginError: Failed
to connect with wallet. Failed to login with openlogin"
import { Web3AuthCore } from ***@***.***/core";
import {
WALLET_ADAPTERS,
CHAIN_NAMESPACES,
SafeEventEmitterProvider
} from ***@***.***/base";
import { OpenloginAdapter } from ***@***.***/openlogin-adapter";
all this packages i'm using it cannot work on jsx files but if i was all
this packages in typescript project tsx file it will work properly
Thanks
—
Reply to this email directly, view it on GitHub
<#1383 (reply in thread)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AFOYNULQ7LOJRP6PKNEBQ63WZRLPLANCNFSM6AAAAAAVI5RJQ4>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
Beta Was this translation helpful? Give feedback.
-
Guys
Pls respond as we are eager to know the way forward.
Thanks
Sundeep
On Mon, 27 Feb 2023, 6:58 pm Sundeep Khisty, ***@***.***>
wrote:
… Thanks Sandip.
Web3 team pls let us know what are we missing to make web3 modal work.
Thanks
Sundeep
On Mon, 27 Feb 2023, 1:14 pm sandippa26, ***@***.***> wrote:
> Hello @yashovardhan <https://github.com/yashovardhan> i'm facing an
> issue when using web3auth and auth0 it will give error "WalletLoginError:
> Failed to connect with wallet. Failed to login with openlogin"
> import { Web3AuthCore } from ***@***.***/core";
> import {
> WALLET_ADAPTERS,
> CHAIN_NAMESPACES,
> SafeEventEmitterProvider
> } from ***@***.***/base";
> import { OpenloginAdapter } from ***@***.***/openlogin-adapter";
> all this packages i'm using it cannot work on jsx files but if i was all
> this packages in typescript project tsx file it will work properly
> Thanks
>
> —
> Reply to this email directly, view it on GitHub
> <#1383 (reply in thread)>,
> or unsubscribe
> <https://github.com/notifications/unsubscribe-auth/AFOYNULQ7LOJRP6PKNEBQ63WZRLPLANCNFSM6AAAAAAVI5RJQ4>
> .
> You are receiving this because you were mentioned.Message ID:
> ***@***.***>
>
|
Beta Was this translation helpful? Give feedback.
-
Hey folks, We have shifted our discussions to community.web3auth.io Can you please ask your questions there instead? Here's a link to your imported thread for reference purposes. You can either reply there itself or create a new topic. https://community.web3auth.io/t/safeeventemitterprovider-for-react-jsx-format/2925 |
Beta Was this translation helpful? Give feedback.
-
Hi Web3 experts,
Pls let us know your response to our simple question whether you support
jsx when using safeemitter lib or give your number to call you all to
discuss.
Details of the log is also been supplied.
Thanks
Sundeep
…On Tue, 28 Feb 2023, 12:02 pm Yashovardhan Agrawal, < ***@***.***> wrote:
Hey folks,
We have shifted our discussions to community.web3auth.io
Can you please ask your questions there instead?
Here's a link to your imported thread for reference purposes. You can
either reply there itself or create a new topic.
https://community.web3auth.io/t/safeeventemitterprovider-for-react-jsx-format/2925
—
Reply to this email directly, view it on GitHub
<#1383 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AFOYNUM33EOWDTOATZWOUHDWZWLWJANCNFSM6AAAAAAVI5RJQ4>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
Beta Was this translation helpful? Give feedback.
-
Hi there
We are not getting a response from you all.
What should we do?.
Move on to another product or wait.
Let us know
Thanks
Sundeep
…On Tue, 28 Feb 2023, 12:02 pm Yashovardhan Agrawal, < ***@***.***> wrote:
Hey folks,
We have shifted our discussions to community.web3auth.io
Can you please ask your questions there instead?
Here's a link to your imported thread for reference purposes. You can
either reply there itself or create a new topic.
https://community.web3auth.io/t/safeeventemitterprovider-for-react-jsx-format/2925
—
Reply to this email directly, view it on GitHub
<#1383 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AFOYNUM33EOWDTOATZWOUHDWZWLWJANCNFSM6AAAAAAVI5RJQ4>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
Beta Was this translation helpful? Give feedback.
-
What do you suggest I do? To Seek a response as we are awaiting since
couple of days.
Thanks
Sundeep
…On Thu, 2 Mar 2023, 8:50 am Yashovardhan Agrawal, ***@***.***> wrote:
Hey @sundeep138 <https://github.com/sundeep138>
Please ask your question on https://community.web3auth.io
Please understand that our support is specific to that platform.
I cannot share my number unfortunately.
—
Reply to this email directly, view it on GitHub
<#1383 (reply in thread)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AFOYNUPBONNQ46W5IRW76VTW2AGY7ANCNFSM6AAAAAAVI5RJQ4>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
Beta Was this translation helpful? Give feedback.
-
Ok Yash. we will send you the whole code. We will appreciate if you can
give us a faster response.
I will be travelling back to Australia and whilst in India, I want this
issue to be resolved to use Web3 auth WITHOUT typescript.
Thanks
Sundeep
…On Thu, 2 Mar 2023 at 15:13, Yashovardhan Agrawal ***@***.***> wrote:
As mentioned, please ask on https://community.web3auth.io, share your
whole code related to web3auth. You'll get a proper resolution after that
only. It is impossible for us to give you an answer with half information
about how your code is structured. We have tried using Web3Auth in jsx and
couldn't replicate your error.
—
Reply to this email directly, view it on GitHub
<#1383 (reply in thread)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AFOYNUNFYFQLVJSHTZYZIMTW2ANAJANCNFSM6AAAAAAVI5RJQ4>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
Beta Was this translation helpful? Give feedback.
-
Hi yash
FYI our code for your review and let us know the workaround for not using
typescript.
Thanks
Sundeep
import React, { useState, useEffect } from 'react';
import { Container, Row, Col, Form } from 'react-bootstrap';
import {
Button,
Icon,
TextField
} from ***@***.***/core';
import {
ScrollingProvider,
useScrollSection,
Section,
} from 'react-scroll-section';
// import { WALLET_ADAPTERS, CHAIN_NAMESPACES, SafeEventEmitterProvider }
from ***@***.***/base";
import { Web3AuthCore } from ***@***.***/core";
// import { OpenloginAdapter } from ***@***.***/openlogin-adapter";
import walletConnectProvider from ***@***.***/web3-provider'
// import {EventEmitter} from 'events';
// import { SafeEventEmitterProvider } from
***@***.***/network/lib/react';
// import Web3Modal from 'web3modal';
// import { Web3Auth } from ***@***.***/modal";
import { Web3Auth } from ***@***.***/web3auth";
// import {Auth0LockPasswordless} from 'auth0-lock';
// import { Web3AuthCore } from ***@***.***/core";
import {
WALLET_ADAPTERS,
CHAIN_NAMESPACES,
SafeEventEmitterProvider
} from ***@***.***/base";
import { OpenloginAdapter } from ***@***.***/openlogin-adapter";
import { Link } from 'react-router-dom';
// import { useAuth0 } from ***@***.***/auth0-react";
// import RPC from "../../services/web3RPC";
const clientId =
"BEglQSgt4cUWcj6SKRdu5QkOXTsePmMcusG5EAoyjyOYKlVRjIF1iCNnMOTfpzCiunHRrMui8TIwQPXdkQ8Yxuk";
const StaticMenu = (props) => {
const [web3auth, setWeb3auth] = useState(null);
const [provider, setProvider] = useState(null);
const homeSection = useScrollSection('home');
const pricingSection = useScrollSection('pricingTable');
const helpSection = useScrollSection('help');
useEffect(() => {
const init = async () => {
try {
const web3auth = new Web3AuthCore({
clientId,
chainConfig: {
chainNamespace: CHAIN_NAMESPACES.EIP155,
chainId: "0x5",
},
});
const openloginAdapter = new OpenloginAdapter({
adapterSettings: {
network: "mainnet",
uxMode: "popup",
loginConfig: {
jwt: {
verifier: "web3auth-auth0-demo",
typeOfLogin: "jwt",
clientId: "294QRkchfq2YaXUbPri7D6PH7xzHgQMT",
},
},
},
});
// web3auth.configureAdapter(openloginAdapter);
web3auth.configureAdapter(openloginAdapter)
setWeb3auth(web3auth);
await web3auth.init();
if (web3auth.provider) {
setProvider(web3auth.provider);
}
} catch (error) {
console.error(error);
}
};
init();
}, []);
const login = async () => {
try {
if (!web3auth) {
console.log("web3auth not initialized yet");
return;
}
const web3authProvider = await
web3auth.connectTo(WALLET_ADAPTERS.OPENLOGIN, {
loginProvider: "jwt",
extraLoginOptions: {
domain: "https://shahbaz-torus.us.auth0.com", // Please append
"https://" before your domain
verifierIdField: "sub",
},
});
setProvider(web3authProvider);
} catch (error) {
console.log(error);
}
};
return (
<nav className="navbar navbar-expand-lg navbar-light fixed-top py-4
d-block" data-navbar-on-scroll="data-navbar-on-scroll">
<div className="container">
<div className="StaticMenu">
<>
<button onClick={login}>Login</button>
</>
</div>
<form className="ps-lg-5"><div className="btn btn-light
order-1 order-lg-0">login
<svg className="bi bi-person-fill" xmlns="
http://www.w3.org/2000/svg" width="16" height="16" fill="currentColor"
viewBox="0 0 16 16">
<path d="M3 14s-1 0-1-1 1-4 6-4 6 3 6 4-1 1-1 1H3zm5-6a3
3 0 1 0 0-6 3 3 0 0 0 0 6z"></path>
</svg></div></form>
</Link>
}
</div>
</div>
</nav>
);
};
export default StaticMenu;
…On Wed, 8 Mar 2023 at 15:04, Sundeep Khisty ***@***.***> wrote:
Ok Yash. we will send you the whole code. We will appreciate if you can
give us a faster response.
I will be travelling back to Australia and whilst in India, I want this
issue to be resolved to use Web3 auth WITHOUT typescript.
Thanks
Sundeep
On Thu, 2 Mar 2023 at 15:13, Yashovardhan Agrawal <
***@***.***> wrote:
> As mentioned, please ask on https://community.web3auth.io, share your
> whole code related to web3auth. You'll get a proper resolution after that
> only. It is impossible for us to give you an answer with half information
> about how your code is structured. We have tried using Web3Auth in jsx and
> couldn't replicate your error.
>
> —
> Reply to this email directly, view it on GitHub
> <#1383 (reply in thread)>,
> or unsubscribe
> <https://github.com/notifications/unsubscribe-auth/AFOYNUNFYFQLVJSHTZYZIMTW2ANAJANCNFSM6AAAAAAVI5RJQ4>
> .
> You are receiving this because you were mentioned.Message ID:
> ***@***.***>
>
|
Beta Was this translation helpful? Give feedback.
-
Also we are using https://shahbaz-torus.us.auth0. and SVG namespace
(w3.org) <https://www.w3.org/2000/svg>
Thanks
Sundeep
…On Wed, 8 Mar 2023 at 15:04, Sundeep Khisty ***@***.***> wrote:
Ok Yash. we will send you the whole code. We will appreciate if you can
give us a faster response.
I will be travelling back to Australia and whilst in India, I want this
issue to be resolved to use Web3 auth WITHOUT typescript.
Thanks
Sundeep
On Thu, 2 Mar 2023 at 15:13, Yashovardhan Agrawal <
***@***.***> wrote:
> As mentioned, please ask on https://community.web3auth.io, share your
> whole code related to web3auth. You'll get a proper resolution after that
> only. It is impossible for us to give you an answer with half information
> about how your code is structured. We have tried using Web3Auth in jsx and
> couldn't replicate your error.
>
> —
> Reply to this email directly, view it on GitHub
> <#1383 (reply in thread)>,
> or unsubscribe
> <https://github.com/notifications/unsubscribe-auth/AFOYNUNFYFQLVJSHTZYZIMTW2ANAJANCNFSM6AAAAAAVI5RJQ4>
> .
> You are receiving this because you were mentioned.Message ID:
> ***@***.***>
>
|
Beta Was this translation helpful? Give feedback.
-
We tried the following
npm install --save-dev @types/web3auth__core
npm ERR! 404 Not Found - GET ***@***.***%2fweb3-auth
- Not found npm ERR! 404 npm ERR! 404 ***@***.***/web3-auth@*' is not in this
registry. npm ERR! 404 npm ERR! 404 Note that you can also install from a
npm ERR! 404 tarball, folder, http url, or git url. npm ERR! A complete log
of this run can be found in: npm ERR!
C:\Users\sunde\AppData\Local\npm-cache\_logs\2023-03-09T07_44_47_313Z-debug-0.log
Thanks
Sundeep
…On Wed, 8 Mar 2023 at 15:04, Sundeep Khisty ***@***.***> wrote:
Ok Yash. we will send you the whole code. We will appreciate if you can
give us a faster response.
I will be travelling back to Australia and whilst in India, I want this
issue to be resolved to use Web3 auth WITHOUT typescript.
Thanks
Sundeep
On Thu, 2 Mar 2023 at 15:13, Yashovardhan Agrawal <
***@***.***> wrote:
> As mentioned, please ask on https://community.web3auth.io, share your
> whole code related to web3auth. You'll get a proper resolution after that
> only. It is impossible for us to give you an answer with half information
> about how your code is structured. We have tried using Web3Auth in jsx and
> couldn't replicate your error.
>
> —
> Reply to this email directly, view it on GitHub
> <#1383 (reply in thread)>,
> or unsubscribe
> <https://github.com/notifications/unsubscribe-auth/AFOYNUNFYFQLVJSHTZYZIMTW2ANAJANCNFSM6AAAAAAVI5RJQ4>
> .
> You are receiving this because you were mentioned.Message ID:
> ***@***.***>
>
|
Beta Was this translation helpful? Give feedback.
-
Why you guys are not responding.?
…On Wed, 8 Mar 2023 at 15:04, Sundeep Khisty ***@***.***> wrote:
Ok Yash. we will send you the whole code. We will appreciate if you can
give us a faster response.
I will be travelling back to Australia and whilst in India, I want this
issue to be resolved to use Web3 auth WITHOUT typescript.
Thanks
Sundeep
On Thu, 2 Mar 2023 at 15:13, Yashovardhan Agrawal <
***@***.***> wrote:
> As mentioned, please ask on https://community.web3auth.io, share your
> whole code related to web3auth. You'll get a proper resolution after that
> only. It is impossible for us to give you an answer with half information
> about how your code is structured. We have tried using Web3Auth in jsx and
> couldn't replicate your error.
>
> —
> Reply to this email directly, view it on GitHub
> <#1383 (reply in thread)>,
> or unsubscribe
> <https://github.com/notifications/unsubscribe-auth/AFOYNUNFYFQLVJSHTZYZIMTW2ANAJANCNFSM6AAAAAAVI5RJQ4>
> .
> You are receiving this because you were mentioned.Message ID:
> ***@***.***>
>
|
Beta Was this translation helpful? Give feedback.
-
Hi there
Can anybody help us as we understand that SafeEventEmitterProvider may be coded in typescript.
Our dev team are using react that is predominatly in jsx files.
Now the problem statement is that it does not compile when using SafeEventEmitterProvider in app.jsx.
So got stuck. anywork around or pointers to resolving this issue will be great to learn and resolve our issue.
Thanks
Sundeep
Beta Was this translation helpful? Give feedback.
All reactions