Include a *.jzip file extension

Include a *.jzip file extension which automatically renames any *.js file iff it detects the file has been packed with excessive binary data, or is being used as an archive ( ie. excessive or large file size with few or no function calls or inaccessible address space for non-executable routines )

1 Like

One could probably make their build tools automatically do their sort of detection and spit out a .zip.js file if this happens.

I don't think the .js extension is part of the spec in the first place - it's probably just a pseudo-standard the community uses, so anyone's welcome to make up additional file extensions if they so want.

2 Likes

This post was flagged by the community and is temporarily hidden.

I’m not sure what the sarcasm is for. The language spec has no such concept as “file”, “archive”, or “executable routines”. This simply is an impossible thing for the language spec to discuss.

node already has policies, and browsers don’t have a filesystem, so I’m also not sure why this would be needed at all.

2 Likes