dp
PD𧩠Plasmo Developers
β’Created by dp on 4/1/2024 in #πΎextension
plasmo dev is failing
here is the verbose output
(...)
π‘ 4 | @plasmohq/optimizer-es: tabs/import-wallet-with-socials.a896c681.js tabs/import-wallet-with-socials.[hash].js /Users/dp/work/extension
π‘ 5 | optimizer-es: skipped
(...)
π‘ 9 | optimizer-es: skipped
/Users/dp/work/extension/node_modules/@plasmohq/parcel-compressor-utf8/dist/index.js:1
var a=Object.defineProperty;var d=Object.getOwnPropertyDescriptor;var p=Object.getOwnPropertyNames;var u=Object.prototype.hasOwnProperty;var l=(o,r)=>{for(var e in r)a(o,e,{get:r[e],enumerable:!0})},c=(o,r,e,n)=>{if(r&&typeof r=="object"||typeof r=="function")for(let t of p(r))!u.call(o,t)&&t!==e&&a(o,t,{get:()=>r[t],enumerable:!(n=d(r,t))||n.enumerable});return o};var C=o=>c(a({},"__esModule",{value:!0}),o);var g={};l(g,{default:()=>h});module.exports=C(g);var i=require("@parcel/plugin");var m=require("stream"),f=require("string_decoder"),s=class extends m.Transform{decoder=new f.StringDecoder("utf8");_transform(r,e,n){n(null,this.transformChunk(this.decoder.write(r)))}_flush(r){let e=this.decoder.end();e?r(null,this.transformChunk(e)):r()}transformChunk(r){return Array.from(r).map(e=>e.charCodeAt(0)<=127?e:"\\u"+("0000"+e.charCodeAt(0).toString(16)).slice(-4)).join("")}};var h=new i.Compressor({async compress({stream:o}){return{stream:o.pipe(new s)}}});
RangeError: Invalid array length
at Function.from (<anonymous>)
at s.transformChunk (/Users/dp/work/extension/node_modules/@plasmohq/parcel-compressor-utf8/dist/index.js:1:783)
at s._transform (/Users/dp/work/extension/node_modules/@plasmohq/parcel-compressor-utf8/dist/index.js:1:641)
at Transform._write (node:internal/streams/transform:171:8)
at writeOrBuffer (node:internal/streams/writable:564:12)
at _write (node:internal/streams/writable:493:10)(...)
at Readable.emit (node:events:518:28)
at Readable.read (node:internal/streams/readable:780:10)
(...)
π‘ 4 | @plasmohq/optimizer-es: tabs/import-wallet-with-socials.a896c681.js tabs/import-wallet-with-socials.[hash].js /Users/dp/work/extension
π‘ 5 | optimizer-es: skipped
(...)
π‘ 9 | optimizer-es: skipped
/Users/dp/work/extension/node_modules/@plasmohq/parcel-compressor-utf8/dist/index.js:1
var a=Object.defineProperty;var d=Object.getOwnPropertyDescriptor;var p=Object.getOwnPropertyNames;var u=Object.prototype.hasOwnProperty;var l=(o,r)=>{for(var e in r)a(o,e,{get:r[e],enumerable:!0})},c=(o,r,e,n)=>{if(r&&typeof r=="object"||typeof r=="function")for(let t of p(r))!u.call(o,t)&&t!==e&&a(o,t,{get:()=>r[t],enumerable:!(n=d(r,t))||n.enumerable});return o};var C=o=>c(a({},"__esModule",{value:!0}),o);var g={};l(g,{default:()=>h});module.exports=C(g);var i=require("@parcel/plugin");var m=require("stream"),f=require("string_decoder"),s=class extends m.Transform{decoder=new f.StringDecoder("utf8");_transform(r,e,n){n(null,this.transformChunk(this.decoder.write(r)))}_flush(r){let e=this.decoder.end();e?r(null,this.transformChunk(e)):r()}transformChunk(r){return Array.from(r).map(e=>e.charCodeAt(0)<=127?e:"\\u"+("0000"+e.charCodeAt(0).toString(16)).slice(-4)).join("")}};var h=new i.Compressor({async compress({stream:o}){return{stream:o.pipe(new s)}}});
RangeError: Invalid array length
at Function.from (<anonymous>)
at s.transformChunk (/Users/dp/work/extension/node_modules/@plasmohq/parcel-compressor-utf8/dist/index.js:1:783)
at s._transform (/Users/dp/work/extension/node_modules/@plasmohq/parcel-compressor-utf8/dist/index.js:1:641)
at Transform._write (node:internal/streams/transform:171:8)
at writeOrBuffer (node:internal/streams/writable:564:12)
at _write (node:internal/streams/writable:493:10)(...)
at Readable.emit (node:events:518:28)
at Readable.read (node:internal/streams/readable:780:10)
7 replies
PD𧩠Plasmo Developers
β’Created by dp on 3/21/2024 in #πΎextension
Bug : EAGAIN when use `plasmo package`
EAGAIN when using
It then starts to use a lot of memory
plasmo package
% yarn package --verbose
yarn run v1.22.22
warning package.json: No license field
$ plasmo package --verbose
π‘ 0 | Running command: package
π£ Plasmo v0.85.2
π΄ The Browser Extension Framework
π΅ INFO | Prepare to package the extension bundle...
π‘ 1 | Creating Manifest Factory...
π‘ 2 | Ensure exists: /Users/dp/work/extension/.plasmo
π‘ 3 | /Users/dp/work/extension/assets/icon.png found, creating resized icons
π‘ 4 | Creating static templates for popup
π‘ 5 | Creating static templates for options
π‘ 6 | Creating static templates for newtab
π‘ 7 | Creating static templates for devtools
π‘ 8 | Creating static templates for sidepanel
(...)
π‘ 18 | { messageHandlerList: [], portHandlerList: [] }
π‘ 19 | Creating BGSW entry
π‘ 20 | Hash changed, updating manifest
π΄ ERROR | EAGAIN
π‘ 21 | Error: EAGAIN
at new Worker (node:internal/worker:291:19)
at wk (file:///Users/dp/work/extension/node_modules/fflate/esm/index.mjs:22:13)
at wrkr (file:///Users/dp/work/extension/node_modules/fflate/esm/index.mjs:893:12)
at astrmify (file:///Users/dp/work/extension/node_modules/fflate/esm/index.mjs:930:13)
at new AsyncDeflate (file:///Users/dp/work/extension/node_modules/fflate/esm/index.mjs:1086:9)
at new AsyncZipDeflate (file:///Users/dp/work/extension/node_modules/fflate/esm/index.mjs:1949:18)
at file:///Users/dp/work/extension/node_modules/plasmo/dist/index.js:166:10563
at new Promise (<anonymous>)
at Qr (file:///Users/dp/work/extension/node_modules/plasmo/dist/index.js:166:10341)
at async Zh (file:///Users/dp/work/extension/node_modules/plasmo/dist/index.js:166:11510)
π΄ EXIT | This program will terminate in 3 seconds...
% yarn package --verbose
yarn run v1.22.22
warning package.json: No license field
$ plasmo package --verbose
π‘ 0 | Running command: package
π£ Plasmo v0.85.2
π΄ The Browser Extension Framework
π΅ INFO | Prepare to package the extension bundle...
π‘ 1 | Creating Manifest Factory...
π‘ 2 | Ensure exists: /Users/dp/work/extension/.plasmo
π‘ 3 | /Users/dp/work/extension/assets/icon.png found, creating resized icons
π‘ 4 | Creating static templates for popup
π‘ 5 | Creating static templates for options
π‘ 6 | Creating static templates for newtab
π‘ 7 | Creating static templates for devtools
π‘ 8 | Creating static templates for sidepanel
(...)
π‘ 18 | { messageHandlerList: [], portHandlerList: [] }
π‘ 19 | Creating BGSW entry
π‘ 20 | Hash changed, updating manifest
π΄ ERROR | EAGAIN
π‘ 21 | Error: EAGAIN
at new Worker (node:internal/worker:291:19)
at wk (file:///Users/dp/work/extension/node_modules/fflate/esm/index.mjs:22:13)
at wrkr (file:///Users/dp/work/extension/node_modules/fflate/esm/index.mjs:893:12)
at astrmify (file:///Users/dp/work/extension/node_modules/fflate/esm/index.mjs:930:13)
at new AsyncDeflate (file:///Users/dp/work/extension/node_modules/fflate/esm/index.mjs:1086:9)
at new AsyncZipDeflate (file:///Users/dp/work/extension/node_modules/fflate/esm/index.mjs:1949:18)
at file:///Users/dp/work/extension/node_modules/plasmo/dist/index.js:166:10563
at new Promise (<anonymous>)
at Qr (file:///Users/dp/work/extension/node_modules/plasmo/dist/index.js:166:10341)
at async Zh (file:///Users/dp/work/extension/node_modules/plasmo/dist/index.js:166:11510)
π΄ EXIT | This program will terminate in 3 seconds...
79 replies
PD𧩠Plasmo Developers
β’Created by dp on 2/15/2024 in #π°newbie
Is there a way to build a webapp or electron app based on a Plasmo project?
Hello
We're building a browser extension, but for the sake of testing we may just test the web-app part without all chrome APIs part; is there a way to do a distribution as a webapp?
Another question, can we target to electron in the future?
2 replies