Skip to content
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

Feature: add custom network #274

Merged
merged 12 commits into from
Nov 16, 2023
Merged

Conversation

bogos
Copy link
Contributor

@bogos bogos commented Nov 13, 2023

  • Add custom network modal selector
  • Validate selected network

Copy link

vercel bot commented Nov 13, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
polkadot-contract-wizard ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 15, 2023 11:33pm

@0xLucca
Copy link
Collaborator

0xLucca commented Nov 14, 2023

The code in the previous commit is functional but appears messy and lacks clarity due to asynchronous operations within useEffect. Despite its smelly nature, it successfully initializes the API and manages state. Consider refactoring for improved readability when possible.

Copy link
Collaborator

@henrypalacios henrypalacios left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great changes @bogos 🤝.

I will merge and leave you the commentary on what needs to be improved.


useEffect(() => {
if (networkConnected) {
if (!fetchApi) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤔 This logic is not stable, what happen if fetchApi returns after useEffect is executed?

@henrypalacios henrypalacios merged commit c2314b4 into develop Nov 16, 2023
3 checks passed
@henrypalacios henrypalacios deleted the feature/add-custom-network branch November 16, 2023 13:23
Copy link
Collaborator

@0xLucca 0xLucca left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The logic works as expected. There are some minor issues to fix in the UI

}
}

const formData = {
name: useFormInput<string>('test', [notEmpty]),
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Here in the form data the placeholder for the name seems like an address

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants