Skip to content
This repository has been archived by the owner on Dec 16, 2022. It is now read-only.

Unpack the main-unminified.js bundle into separate module files #130

Open
activescott opened this issue Mar 17, 2018 · 1 comment
Open
Assignees

Comments

@activescott
Copy link

I believe we can iteratively unpack that 153,953 line file ($#@!$@) into it's respective module files again. This would do wonders for making the codebase maintainable and potentially a sane base for the next-gen-ui.

I think I'll take a whack at this and see if I can get into it and see a light at the end of the tunnel.

@activescott activescott self-assigned this Mar 17, 2018
activescott added a commit to activescott/forkdelta.github.io that referenced this issue Mar 18, 2018
@activescott
Copy link
Author

activescott commented Mar 18, 2018

I think it is quite possible. See branch referenced above for a script that will unpack main-unminified.js. I'm sure it's not going to work just immediately, but I'm optimistic with some trial & error after the unpack we can get it all working again without the 150K file anymore.

Some known things that need done:

  • Setup a bundler to pack jsapp/app.js module with webpack, rollupjs, browserfy, or something (after moving scripts/unpacked_modules/* jsapp/.
  • I did some hacky name mangling in filterPreferredModuleNames in the script to avoid obsessive duplication of modules. Technically it may not be absolutely necessary (modules would just be loaded multiple times?), and I fear I may have mangled some of the original paths.
  • As expected there are TONS of public packages/modules in the unpacked_modules so an extraordinary amount of removal of files and replacing with npm modules could be done. Some that I remember seeing: react, bignumber, crypto, lodash, browserfy, buffer, qs, punycode, sha1, sha256, aws, etc.

activescott added a commit to activescott/forkdelta.github.io that referenced this issue Mar 18, 2018
activescott added a commit to activescott/forkdelta.github.io that referenced this issue Mar 18, 2018
activescott added a commit to activescott/forkdelta.github.io that referenced this issue Mar 18, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant