Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

SlimShady's avatar

React - "merge" chunk.js and chunk.js.map

Hi, I have to add a simple feature to React App, but all I have is access to server files that are minified. There are files called chunk.js and chunk.js.map. I see that in the debugger browsers somehow "merge" these files and make reading them easy. However, if I open the chunk.js file in my code editor, it is hard to read it even if I add indentation. Variables' names are "minified" too and that makes it hard to read. Is there a possibility to manually "merge" chunk.js and chunk.js.map files so that variables' names become "normal" and easy to read?

0 likes
5 replies
SlimShady's avatar

Thanks for the help, but I think I didn't make myself clear. Unminifing the file is quite easy, but I want to get the variables' and functions' names from the development process. Variables are named like "a", "n", "e", etc. I thought that If the browser knows how to "merge" map files and js files together, I can do that too. The code looks like this:

return n.a.createElement("div", {
                            className: "task-block open-question"
                        } 
// Rest of the code

And there are thousands of lines of code like this.

ManuelF's avatar

Hi @slimshady and @sinnbeck ,

Solution provided by @sinnbeck allowed me to return files to a known structure (Thank you!), but once I am done with the editing process, how can I re-chunk the project to have the original structure and yet keeping my changes?

Thank you

Please or to participate in this conversation.