Node.js core module fallback in vite as webpack

Viewed 1550

In webpack when I get the error "Uncaught TypeError: path.join is not a function" I could add the configuration

resolve: {
    fallback: { "path": require.resolve("path-browserify") }
}

to solve.

How do I do such thing in vite?

1 Answers
Related