• Zach Pomerantz's avatar
    perf(swap): initialize swap inputs from url (#2402) · 8de6bb6d
    Zach Pomerantz authored
    * fix(swap): use undefined as initial currencyId state
    
    Null should be used for a selection state, not an unknown state. undefined may signify that a currency was passed in the URL but not yet parsed.
    
    * perf(swap): initialize swap with url
    
    Initializes SwapState with URL parameters so that currency input may be rendered on the first frame.
    
    * test(swap): update hooks tests
    
    * test: fix casing
    
    * fix: check nullish to allow eg 0
    8de6bb6d
index.tsx 10.6 KB