Invalid or incompatible cached data (cachedDataRejected) with Vue and Electron
See original GitHub issueHi,
I am using Vuejs and Electron using this plugin: https://github.com/nklayman/vue-cli-plugin-electron-builder
I’m trying to protect the electron code using bytenode but I’m running onto the Invalid or incompatible cached data
error when running the packaged application.
I have created a basic repository to replicate the error https://github.com/alexsnkr/vue-electron-bytenode
If I run the builder to only generate the package directory I can run electron .
from the bundled
directory and it runs using the .jsc file just fine, but when I package it for distribution it errors.
I have gone through the issues from people that have ran into the same error, but I’ve had not luck fixing it.
Any help is appreciated,
Thanks.
Issue Analytics
- State:
- Created 3 years ago
- Comments:17 (1 by maintainers)
Top Results From Across the Web
Invalid or incompatible cached data (cachedDataRejected ...
Hi,. I am using Vuejs and Electron using this plugin: https://github.com/nklayman/vue-cli-plugin-electron-builder.
Read more >qjh/vue-electron-bytenode - Gitee
How to replicate the Invalid or incompatible cached data (cachedDataRejected) error. run yarn build:dir rename dist_electron/bundled/background.js to ...
Read more >How to Compile Node.js Code Using Bytenode? - HackerNoon
In this post, I will show you how to “truly” compile Node.js (JavaScript) code to V8 Bytecode. This allows you to hide or...
Read more >Building an app with Electron and Vue - LogRocket Blog
If you've worked with Vue before, it's simple to get started with Electron. Use the Vue CLI plugin for Electron Builder and make...
Read more >Node.js v19.3.0 Documentation
Script cached data; DEP0111: process.binding(); DEP0112: dgram private APIs ... _unrefActive(); DEP0128: modules with an invalid main entry and an index.js ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
const { app, BrowserWindow } = require(‘electron’) function createWindow () { // 创建浏览器窗口 let win = new BrowserWindow({ width: 800, height: 600, webPreferences: { nodeIntegration: true } })
// 加载index.html文件 win.webContents.openDevTools() win.loadFile(‘index.html’) } app.whenReady().then(createWindow)
const bytenode = require(“bytenode”); // 编译二进制文件 let compiledFilename = bytenode.compileFile({ filename: ‘./test.js’, output: ‘./test.jsc’ // if omitted, it defaults to ‘/path/to/your/file.jsc’ }); require(“./test.jsc”)
window.onload = () => { const div = document.querySelector(“div”);
div.innerText = “哈哈” }
Compile with nodejs. The version of nodejs V8 engine is different from that of electron V8 engine. That’s what happened.