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

Core & Hooks SDK #224

Merged
merged 41 commits into from
Apr 25, 2024
Merged

Conversation

ugur-eren
Copy link
Collaborator

@ugur-eren ugur-eren commented Apr 22, 2024

For core pacakge, these methods added to the Factory:

  • getBaseMemecoin returns the base details of the memecoin. Name, symbol, total supply, owner etc.
  • getMemecoinLaunchData returns the liquidity, team allocation and quote token of the memecoin
  • getMemecoin returns the results of both base memecoin and memecoin launch data methods
  • getStartingMarketCap returns the starting market cap by the given quote token price
  • getDeployCalldata returns the transaction calldata for deployment
  • getEkuboLaunchCalldata returns the calldata for launch on ekubo
  • getStandardAMMLaunchCalldata returns the calldata for launch on jediswap and starkdefi

For hooks package, these hooks added:

  • useBaseMemecoin returns the result of Factory.getBaseMemecoin
  • useMemecoinLaunchData returns the result of Factory.getMemecoinLaunchData
  • useMemecoin returns the result of Factory.getMemecoin
  • useQuoteToken returns the quote token information by the given address
  • useQuoteTokenPrice returns the quote token price by the given address

This PR also adds a new entrypoints constants to the core package.

Copy link

vercel bot commented Apr 22, 2024

@ugur-eren is attempting to deploy a commit to the StarknetID Team on Vercel.

A member of the Team first needs to authorize it.

@ugur-eren ugur-eren marked this pull request as draft April 22, 2024 08:00
@ugur-eren ugur-eren changed the base branch from main to feat/monorepo-reorg April 22, 2024 12:13
@0xChqrles
Copy link
Contributor

getDeployCalldata returns the transaction calldata for deployment
getEkuboLaunchCalldata returns the calldata for launch on ekubo
getStandardAMMLaunchCalldata returns the calldata for launch on jediswap and starkdefi

Why getting the calldata and not directly executing the call? If it's to compute the memecoin address for the deployment, we can execute the tx and return de computed address.

@ugur-eren
Copy link
Collaborator Author

ugur-eren commented Apr 22, 2024

Hi! Since the SDK only needs a RPC Provider, it can be used without wallet adapters. Developers can choose how they want to sign and execute transactions. However I can create hooks to sign and send transactions using the Starknet React package.

@ugur-eren ugur-eren changed the base branch from feat/monorepo-reorg to main April 22, 2024 14:00
@ugur-eren ugur-eren marked this pull request as ready for review April 23, 2024 11:37
Copy link
Contributor

@0xChqrles 0xChqrles left a comment

Choose a reason for hiding this comment

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

Thanks a lot for your amazing work ! Please review the comments when you can.

packages/core/src/factory/default.ts Outdated Show resolved Hide resolved
packages/hooks/src/components/index.ts Outdated Show resolved Hide resolved
Copy link
Contributor

@0xChqrles 0xChqrles left a comment

Choose a reason for hiding this comment

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

lgtm ! We might still have some fixes or modifications to address while starting to integrate it into the frontend, but let's more forward with this PR and merge it as a first version of the SDK 🔥

@0xChqrles 0xChqrles merged commit df4daac into keep-starknet-strange:main Apr 25, 2024
0 of 3 checks passed
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.

2 participants