Coder Social home page Coder Social logo

lifinance / jumper.exchange Goto Github PK

View Code? Open in Web Editor NEW
161.0 161.0 117.0 31.6 MB

Jumper - Multi-Chain Bridging & Swapping (powered by LI.FI)

Home Page: https://jumper.exchange

License: Apache License 2.0

Shell 0.17% CSS 1.79% TypeScript 97.51% Dockerfile 0.26% JavaScript 0.27%
bridge cross-chain dapp defi dex ethereum jump lifi multi-chain react typescript web3

jumper.exchange's People

Contributors

0xakshay avatar 0xsebn avatar abhikumar98 avatar abhishek-lifi avatar addminus avatar arjunbhuptani avatar battmdpkq avatar bojank93 avatar chybisov avatar dennyscode avatar dnnnvx avatar ilijabojanovic avatar jakekidd avatar julien51 avatar kalote avatar laynehaber avatar mathiasmoeller avatar maxklenk avatar michaelpautov avatar nickolasmv avatar oktapodia avatar omahs avatar philippzentner avatar rhlsthrm avatar sanchaymittal avatar serafimcloud avatar tcheee avatar zord4n avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

jumper.exchange's Issues

TRX

can we add tron network?

Dashboard optimizations

  • Separate unverified tokens from the verified ones. Put them in a separate table below the verified ones with a clear headline "Unverified tokens (might be scam - don't fall for large sums of cash that came out of nowhere)"
  • Improve rendering performance
  • Read a wallet addresse's name or allow to set it
  • Allow to filter by coin (just show the balance of.a specific coin across all connected wallets)
  • Allow to filter by wallet

Finalizing bridge-swap error

Whenever bridging from any network to Polygon, meaning there is going to be a swap at the end of all transactions from native token of the sender network (ETH) to MATIC, if there's barely enough gas on the destination chain (Polygon) and the swap fails, and then you cancel the pending transaction by doing a tx with the same Nonce parameter, the failed swap just remains as processing on Jumper forever.

It just says "Waiting for swap transaction", but I already swapped manually after canceling the pending one.

There at least needs to be an ability to cancel the last part of the bridge. It's just forever in progress and there is nothing I can press on the UI to cancel it or to let it know that I finished the swap manually.

Jumper on Shibarium

I would love to see Jumper add Shibarium support. Shibarium is currently in it's early stages and only has the main bridge from the Shib team into Shibarium, which is only through Ethereum. Jumper integrating shibarium would bring a whole new way of users to lifi while also giving users more options to bridge into shibarium because not many people know how to.

Proposal: ZetaChain Integration for Jumper.exchange

Integrating ZetaChain presents an great opportunity for Jumper.exchange as a pioneer in supporting this new blockchain. This early mover advantage can significantly boost Jumper's visibility and credibility within the ZetaChain ecosystem.
Moreover, being among the first to offer a bridge to ZetaChain expands Jumper's user base and enhances liquidity within its ecosystem. Increased transaction volume benefits liquidity providers and users alike, fostering growth and efficiency.

Add more chains support

Cosmos and Zora has started gaining popularity of recent,
I think it would be a good idea if you can add support for them.

i think Skip Protocol, axelar or wormhole has an API which you can use.

Integrate Scroll

Please integrate Scroll into Jumper Exchange otherwise I have to use rhino bridge instead. thanks team!

1Inch sync error handling

getting quotes and swap information from 1Inch might fail with "cannot sync to token 0x..."

On the server, this issue is handled by not return routes.

There is no handling on the front end. Immediately retriggering the swap might not work. The sync issue might take a while to resolve itself.

xPollinate UI Optimizations

  • toggle active/historic transactions by clicking the small arrow
  • show warning if receiving address different to the own address is set
  • save options in local storage

Error: Address Mismatch.

Hey, right now I'm trying to use Li.Fi API and got some issues this error all the time: Error: from address mismatch
Here is my code

const { ethers, Contract, utils } = require('ethers');
const axios = require('axios');

const API_URL = 'https://li.quest/v1';

const MNEMONIC = 'mnemonic mnemonic mnemonic';
const ADDRESS = '0x0000000000'

const fromChain = 'OPT';
const fromToken = 'ETH';
const toChain = 'ARB';
const toToken = 'ETH';
const fromAmount = '2000000000000000';
const fromAddress = ADDRESS;
const slippage = '0.005';
const order = 'RECOMMENDED';
const allowBridges = 'hop';

const provider = new ethers.providers.JsonRpcProvider('https://mainnet.optimism.io', 10);
const wallet = ethers.Wallet.fromMnemonic(MNEMONIC).connect(
    provider);

const getQuote = async (fromChain, toChain, fromToken, toToken, fromAmount, fromAddress, slippage, order, allowBridges) => {
    const result = await axios.get(`${API_URL}/quote`, {
        params: {
            fromChain,
            toChain,
            fromToken,
            toToken,
            fromAmount,
            fromAddress,
            slippage,
            order,
            allowBridges,
        }
    });
    return result.data;
}

const getStatus = async (bridge, fromChain, toChain, txHash) => {
    const result = await axios.get(`${API_URL}/status`, {
        params: {
            bridge,
            fromChain,
            toChain,
            txHash,
        }
    });
    return result.data;
}

const checkAndSetAllowance = async (wallet, tokenAddress, approvalAddress, amount) => {

    const ERC20_ABI = [
        'function allowance(address,address) external view returns(uint256)',
        'function approve(address,uint256) external'
    ]

    if (tokenAddress === ethers.constants.AddressZero) {
        return
    }

    const erc20 = new Contract(tokenAddress, ERC20_ABI, wallet);
    const allowance = await erc20.allowance(await wallet.getAddress(), approvalAddress);

    if (allowance.lt(utils.parseEther(amount))) {
        return erc20.approve(approvalAddress, amount);
    }
}

const run = async () => {
    const quote = await getQuote(
        fromChain, toChain, fromToken, toToken, fromAmount, fromAddress, slippage, order, allowBridges
    );

    await checkAndSetAllowance(
        wallet, quote.action.fromToken.address, quote.estimate.approvalAddress, fromAmount
    );

    const tx = await wallet.sendTransaction(quote.transactionRequest);

    await tx.wait();

    // Only needed for cross-chain transfers
    if (fromChain !== toChain) {
        let result;
        do {
            result = await getStatus(quote.tool, fromChain, toChain, tx.hash);
        } while (result.status !== 'DONE' && result.status !== 'FAILED')
    }
}

run().then(() => {
    console.log('DONE');
});

Maybe someone could help me?
Thnx =)

Display timing information for each step

It would be nice to see how long the different steps take. Especially with connext we are faster than other solutions, and if the network is blocked and we need to wait for a transaction a long time, it would be nice to communicate this to the user.

I imagine a timer which counts seconds while the step is processing and then stops. Showing a sum at the bottom at the end would also be nice.

Screenshot 2021-07-08 at 10 55 39 AM

xPollinate Optimizations

Optimizations:

  • add walletConnect support, eg. using https://docs.blocknative.com/onboard# (#22)
  • (wait for connext/monorepo#306 error of Liquidity Unavailable on UI if the transaction quote errors No bid available - it shares some helpful insight in error context.
  • show errors if step fail
  • hide failed transfers from active transactions list
  • find replaced transaction (eg. speedup)
  • show tx confirmations on the sender prepare and receiver prepares
  • update listeners in nxtp.tsx to check transaction_id and listen to multiple events (to handle multiple transactions in parallel)
  • toggle active/historic transactions by clicking the small arrow
  • show warning if receiving address different to the own address is set
  • save options in local storage
  • ask user to retry signing the signature if finish step takes longer then 5 minutes
  • notify modal if graph returns that the current transfer is already in the finish step
  • rename switch chain button into something like "Change Chain in your wallet to BSC"
  • show new token, balance and add to metamask

Optional:

  • (wait for sdk support) avoid multiple messaging sign in
  • connected with unknown network
  • switch connected account / better disconnect
  • serve font from our domain
  • show balance and max in form
  • check bundle size

Jumper.exchange gives bridge and swap options as the same kind of thing and that's not good

Sorry if I don't explain myself well, English is not my first language.

I recently (just an hour) tried a swap between alts of the BSC network (from ZEE to USDT) and the Jumper.exchange app gave me options to move to other networks (ETH) and I didn't realize it.

I know it's my fault. That I should have read the contracts carefully when signing.

But on the other hand, I think it's problematic that the Jumper.exchange app offers these options without much distinction. And I don't know exactly how it should be resolved, but at least I think the app should make it very clear that it's a swap or a bridge transaction.

Now, at this moment, I have my USDT in ETH. I need gas on this network first. And lose more in fees to return to the BSC network.

Again: it was my fault. But the app could try to help a little (at least) to avoid this.

add custom token to NXTP demo

hello,

i forked your repo , i wanted to add my own custom token instead of the TEST token in your demo Ui. can you pls point me to where to make changes on the code to have my token appear om the UI so i can bridge.?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.