Compile your JS code: New Bytenode support for Electron

This page summarizes the projects mentioned and recommended in the original post on

Our great sponsors
  • Appwrite - The Open Source Firebase alternative introduces iOS support
  • InfluxDB - Access the most powerful time series database as a service
  • Sonar - Write Clean JavaScript Code. Always.
  • asarmor

    Protect asar archive files from extraction

    What are you thoughts on My thinking is I could use bytenode to protect my business logic and use asarmor to make the resulting asar non-trivial to uncompress, giving my renderer some kind of "protection" but without requiring me to turn off context isolation or enable nodeIntegration.

  • bytenode

    A minimalist bytecode compiler for Node.js

    It doesn't appear that there is any performance penalty to using Bytenode. There are some benchmark functions in the repository, but certainly more work could be done to test. My gut feeling is that the minor overhead of loading the binary is balanced out by the minor speed increase by giving V8 a pre-compiled file.

  • Appwrite

    Appwrite - The Open Source Firebase alternative introduces iOS support . Appwrite is an open source backend server that helps you build native iOS applications much faster with realtime APIs for authentication, databases, files storage, cloud functions and much more!

  • electron-bytenode-example

    A basic Hello World boilerplate using Webpack to convert Electron Javascript code to binary using Bytenode and the Bytenode Webpack Plugin

    Take a look at the electron-bytenode-example repository - in particular the preload script. You can see the 'DOMContentLoaded' example there. You need to do that because preload runs before the DOM has been loaded. That example has both nodeIntegration: true and contextIsolation: false. However, the preload script should always have access to both Node and the DOM, so you should be able to set it up so that all of your scripting happens in preload.

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts