Skip to content

Rework react-components to reduce bundle size and improve customizability #126

Open
@samsiegart

Description

@samsiegart

Describe the bug

There are a few issues with @agoric/react-components:

  • Large bundle size (https://fastusdc.agoric.app/ has a 5.8MB JS bundle after compression) mostly due to chain registry and leap elements widget.
  • Difficult to customize wallet modal and IST onboarding popup (see screenshot). Seems like there's an issue with bundling interchain-ui/react within our own package and their styling engine doesn't seem to work well with that. Also we're removing IST altogether so that needs updating regardless (is it going to be BLD now?)

I think these issues can mostly be addressed by requiring the app to provide the dependencies rather than bundling them within the package, and maybe using an API for chain registry instead of bundling, I'll have to explore ideas though.

Possible Acceptance Criteria

If we're able to update the library and READMEs and create a new build of https://github.com/Agoric/fast-usdc-lp-ui with:

  1. A dramatically reduced bundle size
  2. Customized interchain ui components to agoric red instead of blue as shown below
  3. Complexity kept to a minimum, the library is still relatively straightforward to use

Image

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions