A .mpk file in Mendix is just a zipped package, which contains the widget’s source code, XML configs, and any supporting files. So you can extract it as follows:
- Change the extension to .zip and unzip the file
- Explore the contentsInside you’ll find: widget/ folder (usually contains the widget JavaScript/TypeScript source files). widget.xml defines widget properties, events, configuration options.
You can edit the JS/TS source code files in any editor then repack into a zip file. Then rename to mpk and use it by placing in your apps's widgets/ folder.