Vite bundler errors with Brython #2535
Replies: 6 comments
-
@PierreQuentel Any thoughts? (And, for questions like this should I create a GitHub 'Issue' instead of Discussion item?) |
Beta Was this translation helpful? Give feedback.
-
No, sorry, I have no idea why this happens, and I don't have the energy to dive into yet another Javascript bundling tool. Hopefully someone else will. |
Beta Was this translation helpful? Give feedback.
-
Are there any bundlers that work with Brython? |
Beta Was this translation helpful? Give feedback.
-
I don't even know what a bundler is |
Beta Was this translation helpful? Give feedback.
-
I'm also not from the JavaScript world. "modern browsers can load EcmaScript modules, at the time of writing their mechanism for resolving further dependencies is still too primitive to load collections of NPM-distributed modules. … Bundlers are tools that take a given main script (or in some cases multiple scripts), and produce a new, generally bigger, script that has all (or some) of the script's dependencies (and their dependencies, and so on) included." https://codemirror.net/examples/bundle/ And: https://vite.dev/guide/why for Vite vs tools like webpack, Rollup and Parcel |
Beta Was this translation helpful? Give feedback.
-
Brython has no dependency |
Beta Was this translation helpful? Give feedback.
-
Is there a way to use Vite or other bundler in a project that uses Brython? I don't need it to manage the Brython code; just various
node_modules
used in unrelated code.I have 2 independent projects that I'm trying to merge.
But Vite complains: 'the function x already defined' for cases like:
We tried editing some of the above out of
brython.js
but get an error: 'BRYTHON is not defined'Beta Was this translation helpful? Give feedback.
All reactions