jsonform / jsonform

Build forms from JSON Schema. Easily template-able. Compatible with Bootstrap 3 out of the box.
https://jsonform.github.io/jsonform/playground/index.html
MIT License
2.72k stars 553 forks source link

How to use this library with bundler #444

Open vaclavHala opened 3 months ago

vaclavHala commented 3 months ago

Hi, I'd like to use bundler (webpack, rollup, doesn't matter which) to create a single .js file from all of my code + dependencies, one of which is this library.

I have trouble including this particular library because it does not use ESM or commonJS so I think the bundler has no way to "see" code from the lib is reached by my code and does not know what to include.

Have you faced this problem before? Is there a simple solution I'm not seeing? (I guess simply prepending all content from jsonform.js at start of my bundle might work, but I only want to go that way as last resort) Thanks

sdetweil commented 3 months ago

i do not know.. none of my applications require bundling.