TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

QuickJS Running in WebAssembly

93 pointsby angrygoatover 2 years ago

9 comments

dangover 2 years ago
Related:<p><i>QuickJS JavaScript Engine</i> - <a href="https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=30598026" rel="nofollow">https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=30598026</a> - March 2022 (67 comments)<p><i>A small but complete JavaScript engine</i> - <a href="https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=24867103" rel="nofollow">https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=24867103</a> - Oct 2020 (146 comments)<p><i>QuickJS JavaScript Engine</i> - <a href="https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=20411154" rel="nofollow">https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=20411154</a> - July 2019 (261 comments)<p><i>QuickJS JavaScript Engine</i> - <a href="https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=20404503" rel="nofollow">https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=20404503</a> - July 2019 (3 comments)
pyrolisticalover 2 years ago
Running user provided js in quickjs in webassembly in a worker in an sandboxed iframe on a different domain would offer many layers of security
评论 #33679034 未加载
评论 #33680096 未加载
评论 #33679095 未加载
Arathornover 2 years ago
This is very similar to how Third Room’s user generated content engine is being implemented (supporting C, Rust and Zig alongside QuickJS though): <a href="https:&#x2F;&#x2F;thenewstack.io&#x2F;third-room-teases-user-generated-content-for-the-metaverse&#x2F;" rel="nofollow">https:&#x2F;&#x2F;thenewstack.io&#x2F;third-room-teases-user-generated-cont...</a>
lioetersover 2 years ago
Another library I found recently, which has a different take (simpler API) for using QuickJS compiled to WASM:<p><a href="https:&#x2F;&#x2F;github.com&#x2F;taowen&#x2F;define-function" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;taowen&#x2F;define-function</a>
vbezhenarover 2 years ago
Imagine something like &quot;base system&quot; with WebAssembly, bare bones HTML engine with canvas support and no CSS. So now you can just download your favourite JS engine, your favourite HTML, CSS engines. But browser does not necessarily need to sheep those. It would allow to lower the bar for entry into browser market. I think that even a single person could implement that kind of base browser.<p>Of course there&#x27;re many hard questions. For example downloading an entire JS+HTML+CSS engine with every website is not a good approach, some caching must be done. There should not be version hell with every website asking for a different version of engine. But those questions could be approached as a more general web library issues.
评论 #33679822 未加载
评论 #33679776 未加载
评论 #33682721 未加载
评论 #33683480 未加载
jitlover 2 years ago
Hello, library author here. Happy to answer whatever questions you have.
评论 #33698026 未加载
jensneuseover 2 years ago
Is this also possible with Go as the host instead of TypeScript?
评论 #33679404 未加载
anderspitmanover 2 years ago
Because it wouldn&#x27;t be HN if someone didn&#x27;t: <a href="https:&#x2F;&#x2F;www.destroyallsoftware.com&#x2F;talks&#x2F;the-birth-and-death-of-javascript" rel="nofollow">https:&#x2F;&#x2F;www.destroyallsoftware.com&#x2F;talks&#x2F;the-birth-and-death...</a>
Kiroover 2 years ago
Would you use this to run untrusted JS on the server?
评论 #33680587 未加载
评论 #33683253 未加载
评论 #33683355 未加载
评论 #33685565 未加载