I’ve been writing cross-platform apps for the last 6 years. The most common question I get is, “How do you keep track of the code for Android, iOS and [my preferred language here]?”
This post is my attempt at answering that question. I hope to help you understand why GitHub is awesome for building cross-platform apps.
Git is a version control system. It helps you keep track of your work and collaborate with others on a project. You can use it locally or remotely.
One of the most popular ways to use Git is through GitHub, which is an online code hosting platform. GitHub makes it easier to collaborate on projects (and it’s free).
Why GitHub is awesome for cross-platform apps.
When we set out to build the ReactXP framework, we knew it was going to be a difficult project. We wanted to share code between our iOS, Android and Web implementations of the Skype app. We started by looking at what other companies had done in this space and evaluating existing frameworks, like React Native and Cordova.
After careful consideration, we decided that none of the existing frameworks suited our needs. We wanted something more capable than Cordova while also being more lightweight than React Native. In particular, we wanted to be able to share more code between the various platforms than either of those frameworks would allow us to do. However, there were some good ideas in both of these tools that inspired us to build a new set of libraries from scratch that would ultimately become the foundation for ReactXP.
Sharing Code Between Platforms
ReactXP takes advantage of two key features:
JSX – For declaratively describing UI elements as XML tags that can be translated into native widgets by our renderer components.
GitHub is a great platform for sharing code, projects and ideas with the developer community. If you are reading this, I am sure you already know that.
But did you know that GitHub is not just for software developers? GitHub can be used to build cross-platform apps as well! Let me explain how it works.
GitHub has two main functions:
Version Control System (VCS) – Centralized repository where you can store your code and collaborate with others.
GitHub Pages – Static web hosting service where you can deploy web applications without any cost.
You can use VCS to keep the source code of your application in a centralized location and have control over the changes made by multiple contributors. You can also use GitHub Pages to host your application on the internet without paying anything! Isn’t that amazing?
There’s a lot of talk lately about GitHub Codespaces, and how they’re going to change the world. I don’t believe that. However, I do believe that GitHub Codespaces are an interesting product offering from GitHub and may be useful for certain groups of people.
GitHub Codespaces is great for cross platform app development. In this article, I’ll explain why I think so. If you’re interested in reading more about cross-platform app development, you can check out my blog post on the subject here: https://www.bitrise.io/blog/cross-platform-apps-what-you-need-to-know
What is a codespace?
The term “codespace” is an umbrella term for cloud based IDEs. There are many services that provide this kind of service: Gitpod, Codenvy, Eclipse Che, CodeSandbox and others. A codespace is a containerized development environment preconfigured with the project’s dependencies and runtimes. You can connect to it via your browser or IDE.
Most codespaces create a temporary environment when you open them up and dispose of them when you close the window or disconnect from them. This means that any changes you make are gone once you quit the codes
The idea behind Codespaces is to provide a seamless, plug-and-play experience for developers to work together on GitHub. Wherever you are in the world, whatever machine and operating system you’re using, you can access Codespaces from your browser and get to work immediately.
The main goal of Codespaces is to allow developers to focus on the code and not worry about setting up an environment. This could be huge for remote teams who need an easy way to collaborate and code with one another. A common problem in remote teams is that every user has their own setup for developing apps and getting everyone on the same page can be a hassle. With Codespaces, everyone will have access to the same tools and resources in the cloud so they can get started immediately.
If you are a developer, chances are, GitHub is not new to you. GitHub is the largest and most popular repository hosting service for developers. It’s where developers store their code and collaborate with others on software projects big and small.
GitHub has become a very reliable tool for almost every developer out there. As much as it is useful, GitHub gets even better when coupled with other tools that make development easier. And one of these tools is Codespaces – a fully featured VS Code environment that runs in the browser.
GitHub Codespaces provides a containerized cloud-based development environment to make it easier to configure projects, code on the go, and collaborate with team members, all from within your browser or editor.
Codespaces originates from Visual Studio Online, a web editor that Microsoft acquired in October 2019 along with its entire engineering team. Since then it has been renamed as Codespaces and integrated into GitHub.
GitHub Codespaces is now available in limited beta. Sign up and we’ll let you know as soon as you can use it.
GitHub Codespaces: VS Code in the browser
Develop and debug in a full-featured, extensible, and open-source code editor. Then build and deploy your app to any platform.
Because development environments are so important and hard to set up, GitHub Codespaces provides a hosted environment that comes pre-installed with everything you need to get started. You can easily spin up new environments for every project and branch, making it easy to experiment with new approaches and ensure a clean separation between projects.
With Git at the center of your workflow, you can seamlessly move between the desktop and browser with common shortcuts and settings synchronized automatically. Commit from within Codespaces or switch back to your local IDE when you need full power and offline access.
The first supported programming languages are C