简体   繁体   English

相当于JavaScript的Jframe

[英]Jframe equivalent for javascript

Hello I created a checkers game in Java using jframe and now I want to try in javascript to have it be a Web app. 您好,我使用jframe在Java中创建了一个跳棋游戏,现在我想尝试使用javascript使其成为Web应用程序。 Does anyone know what the equivalent of jframe in javascript is? 有人知道javascript中的jframe是什么吗?

That's not really how js works. 这不是js的工作原理。 Any of the visual components which you would associate with something like swing would translate to HTML in this case. 在这种情况下,您将与诸如swing之类的东西相关联的任何视觉组件都将转换为HTML。 All the styling would be CSS, and then all the logic for how things interact would be written in javascript. 所有样式都是CSS,然后所有有关事物交互的逻辑都将用javascript编写。

I suppose a jFrame would be like a div in HTML 我想jFrame就像HTML中的div

Here's a short video if you need a more robust explanation 如果您需要更详尽的说明,请看以下短片

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM