This update introduces the ability to dynamically assign IDs and display names to Web3Auth connectors based on the specified login provider. This enhancement simplifies the management of multiple connectors in a single application, providing clearer identification and better usability in client-side implementations.
Key Changes:
The connector’s id and name are now set based on the loginProvider parameter, falling back to "web3auth" if not specified.
Supports a range of login providers, enhancing the flexibility of the Web3Auth setup process.
Benefits:
Improved Traceability: Each connector can be easily traced in the frontend, beneficial for debugging and user interface logic.
Enhanced Customization: Allows developers to provide a more personalized experience tailored to the login method used.
Simplified Configuration: Reduces the complexity of handling multiple connectors by using identifiable names and IDs.
Example Usage:
Before:
const connector = Web3AuthConnector({ loginProvider: 'google' });
// Previously, this would default to generic IDs and names.
After:
const connector = Web3AuthConnector({ loginProvider: 'google' });
// Now, the connector ID and name will be "google" and "Google", respectively.
This update does not introduce breaking changes to existing implementations but extends the functionality to support a more structured and maintainable approach when dealing with various Web3Auth connectors.
Thanks for your PR, as per suggestion in #128 we are thinking of adding in the name and id parameters separately in the latest update to the connector.
This update introduces the ability to dynamically assign IDs and display names to Web3Auth connectors based on the specified login provider. This enhancement simplifies the management of multiple connectors in a single application, providing clearer identification and better usability in client-side implementations.
Key Changes:
id
andname
are now set based on theloginProvider
parameter, falling back to "web3auth" if not specified.Benefits:
Example Usage:
Before:
After:
This update does not introduce breaking changes to existing implementations but extends the functionality to support a more structured and maintainable approach when dealing with various Web3Auth connectors.