2.5 KiB
+++ +++
{% alert(warning=true) %} This project is currently under development and not yet ready for production. Follow the project on the Fediverse to stay up to date. {% end %}
Native. Cross-platform. Aparoksha.
Start with Simple Views
A view is a piece of the user interface.
Create your own views, such as Avatar, Post, and Timeline.
Combine them into pages, windows, and apps.
struct Timeline: View {
var posts: Posts
var view: Body {
ForEach(posts) { post in
Avatar(user: post.user)
Post(post: post)
}
}
}
The Magic of the State
Each of your views has the ability to store state throughout view updates. Let's create a simple counter view:
struct SearchView: View {
@State private var count = 0
var view: Body {
Button(icon: .minus) {
count -= 1
}
Text("\(count)")
Button(icon: .plus) {
count += 1
}
}
}
Supported Platforms
A list of some backends is available here. They can be combined with Aparoksha in a simple way. Aparoksha itself currently supports GNOME and Windows. What makes the Aparoksha project unique is that each backend is a fully independent project, optimized for its platform. In a cross-platform app, you can leverage the full potential of the individual backends by writing platform-specific bits of code.