Tic Tac Toe Game By Swift UI

Jacob su
2 min readJun 7, 2020

--

In the last post, I wrote a Tic Tac Toe game by Vue.js, then, I just learned a few SwiftUI yesterday, and its document said it’s a declarative UI programming framework and it’s the trending that can be the default option if you chose the programming target newer than IOS 13. What’s more, it would be a way to build UI across All Apple platform, it sounds familiar to Flutter, is it? But the SwiftUI was driven by Swift and only limited to Apple platforms, while the Flutter was driven by Dart and could be running for all platforms.

It seems Flutter would be more advanced, is it? Both of them are declarative UI programming frameworks, but Flutter can be or will be running for all platforms. But don’t ignore Apple’s official support and the attraction of the powerful Swift, It still worth exploring this virgin land.

Then, why rewrote the Tic Tac Toe game by SwiftUI again? It said to be a declarative syntax, which is the trending, React and Vue are declarative ways, and Google’ cross-platform UI framework, Flutter, is build its UI by the declarative way. So what’s declarative UI building looks like? I thought it makes UI programming quite similar to write HTML tags.

So, If Both SwiftUI, Flutter, React, Vue are similar ways to declare its UI like an HTML page, then why not use the Tic Tac Toe to try out by myself. Here it is, it can be running in both IOS and Mac OS.

Tic Tac Toe Vue.JS

--

--