Skip to content

Issues on using rxing-wasm in nextjs #12

@borracciaBlu

Description

@borracciaBlu

"default": "./node-esm.js"

As because of this, the default is the node runtime and it will break used in a PWA.

Possible workaround in nextjs:

// next.config.js

const nextConfig = {
      .
      .
      .
     webpack: function(config, options) {
          config.resolve.alias["rxing-wasm] = path.resolve(__dirname, "./node_modules/rxing-wasm/rxing_wasm.js");
          
          return config;
     }
};

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