我不确定这个问题是否恰当,因为英语不是我的母语。 lua 和 javascript 可以连接在一起吗?我还没有找到任何相关信息。
或者是否有可能,例如在 html 文件中使用两种语言编写脚本,例如
<html>
<head>
</head>
<body>
<script></script>
<?lsp
?>
</body>
</html>
也许可以在这些语言之间共享信息?!
或者是否可以在js中使用lua或在lua中使用js?喜欢
<script><?lsp ?></script>
<?lsp
<script></script>
?>
在前端使用 Lua 有几种选择(这可能就是你的目标,因为你想用 Lua 连接/替换 JS):
- https://github.com/paulcuth/starlight
- https://github.com/gamesys/moonshine
- https://github.com/fengari-lua/fengari
有一些有趣的 WASM 东西正在开发中,例如:
- https://github.com/vvanders/wasm_lua
- https://github.com/serprex/luwa
- https://github.com/fperrad/lua.wasm
对于后端,还有更多选择。最引人注目的可能是:
- https://github.com/leafo/lapis
- https://github.com/daurnimator/lua-http/
- https://github.com/sailorproject/sailor
- https://openresty.org/en/
- https://github.com/sumory/lor
- https://github.com/luvit/luvit
我只列出了一些。有很多。
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)