Skip to content

Compression on build #27

@dead-claudia

Description

@dead-claudia

The udata variable obviously has size issues, already pointed out in #17, but I was thinking that pre-compressing it in the build phase would be able to significantly cut it down in size. For example, using the following process to compress that variable's content:

  1. Stringify the JSON.
  2. Compress it with bzip2 (near the top in both speed and efficiency).
  3. Base64-encode it. This will help remove some redundancy.
  4. Include that as a string in the built source.

And then, on load or first use on the target side:

  1. Decode it.
  2. Decompress it. (should be significantly faster than compression)
  3. Parse the JSON.
  4. Ready to use.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions