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

Tracking(aztec.js): browser errors #8881

Open
4 of 9 tasks
rahul-kothari opened this issue Sep 30, 2024 · 4 comments
Open
4 of 9 tasks

Tracking(aztec.js): browser errors #8881

rahul-kothari opened this issue Sep 30, 2024 · 4 comments
Assignees
Labels
C-aztec.js Component: aztec.js client library T-bug Type: Bug. Something is broken. T-tracking Type: Tracking Issue. This contains tasklists. team-fairies Nico's team
Milestone

Comments

@rahul-kothari
Copy link
Contributor

rahul-kothari commented Sep 30, 2024

Aztec.JS seems to be hard to use on the browser due to various vite errors. Let's change that

Tasks

Preview Give feedback
  1. C-aztec.js from-community
  2. S-blocked
  3. C-bb.js T-bug from-community
  4. A-devops S-needs-discussion
  5. from-community
  6. from-community
  7. signorecello
  8. T-feature-request
@github-project-automation github-project-automation bot moved this to Todo in A3 Sep 30, 2024
@rahul-kothari rahul-kothari added T-bug Type: Bug. Something is broken. C-aztec.js Component: aztec.js client library labels Sep 30, 2024
@iAmMichaelConnor iAmMichaelConnor added the T-tracking Type: Tracking Issue. This contains tasklists. label Oct 2, 2024
@olehmisar
Copy link
Contributor

@rahul-kothari please track #9959 and #9248

@olehmisar
Copy link
Contributor

olehmisar commented Dec 13, 2024

EDIT: the info below is not accurate. It works fine unless I am using some aztec.js contract stuff. I guess the config below only works for bb.js and maybe foundation.

ORIGINAL COMMENT:

An update what is still required as of 0.66.0 to make aztec.js work in browser

In main.ts:

import { Buffer } from 'buffer'

globalThis.Buffer ??= Buffer
// @ts-expect-error
globalThis.process ??= { env: {} }

In vite.config.ts:

export default defineConfig({
  plugins: [
    resolve({
      util: 'export const inspect = {}', // https://github.com/AztecProtocol/aztec-packages/issues/8881
    }),
  ],
  build: {
    target: "esnext",
  },
  optimizeDeps: {
    esbuildOptions: {
      target: "esnext",
    },
  },
});

@olehmisar
Copy link
Contributor

@rahul-kothari track #10741 please

@rahul-kothari
Copy link
Contributor Author

looks like 10741 is closed already @olehmisar ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-aztec.js Component: aztec.js client library T-bug Type: Bug. Something is broken. T-tracking Type: Tracking Issue. This contains tasklists. team-fairies Nico's team
Projects
Status: Todo
Development

No branches or pull requests

6 participants