Skip to content

chore: update to near-api-js 4.0.2#1411

Merged
MantisClone merged 2 commits intomasterfrom
upgrade-near-api-js
Jun 17, 2024
Merged

chore: update to near-api-js 4.0.2#1411
MantisClone merged 2 commits intomasterfrom
upgrade-near-api-js

Conversation

@MantisClone
Copy link
Member

@MantisClone MantisClone commented Jun 14, 2024

Towards #1390

Description of the changes

  • chore: update to near-api-js 4.0.2

Motivation

For near/near-api-js#1194 - to avoid the need to polyfill http and https in React Native environments. I'll be able to test it in https://github.com/RequestNetwork/expo-starter-request-network as soon as the -next version is released to NPM.

Test

Using npm link I verified that this does indeed eliminate the need to polyfill http and https 👍

const fungibleContract = new Contract(nearWalletConnection.account(), token.value, {
changeMethods: [],
viewMethods: ['ft_balance_of'],
useLocalViewExecution: true,
Copy link
Member Author

Choose a reason for hiding this comment

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

This parameter was added in near/near-api-js#1172. I don't fully understand it, but I don't think it will break anything. It might make view functions to the same blockId more efficient.

@MantisClone MantisClone marked this pull request as ready for review June 14, 2024 19:06
@github-actions github-actions bot requested a review from kevindavee June 14, 2024 19:06
@MantisClone MantisClone merged commit 3561cc7 into master Jun 17, 2024
@MantisClone MantisClone deleted the upgrade-near-api-js branch June 17, 2024 13:49
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.

4 participants