我在 html 文件中使用了 xterm.js,通过 src 导入 xterm.js:
<head>
<link rel="stylesheet" href="/static/plugins/xterm/dist/xterm.css" />
<link rel="stylesheet" href="/static/plugins/xterm/dist/addons/fullscreen/fullscreen.css" />
<script src="/static/plugins/xterm/dist/xterm.js"></script>
<script src="/static/plugins/xterm/dist/addons/fullscreen/fullscreen.js"></script>
</head>
<script>
var term = new Terminal();
term.open(element);
</script>
如何应用全屏插件?我参考了官方链接: https ://xtermjs.org/docs/api/addons/fullscreen/ 但不适合我!