Need advice about which tool to choose?Ask the StackShare community!
Apache Cordova vs Mithril: What are the differences?
<Apache Cordova vs Mithril>
1. **Architecture**: Apache Cordova is a platform for building native mobile applications using web technologies, while Mithril is a modern client-side JavaScript framework for building single-page applications.
2. **Build Tools**: Apache Cordova requires additional build tools and setup for compiling and packaging mobile applications for different platforms, whereas Mithril provides a more streamlined development experience with built-in tools for creating SPAs.
3. **Community Support**: Apache Cordova has a larger and more established community with extensive documentation and plugins available for integrating native device functionalities, while Mithril has a smaller but active community that focuses on maintaining the framework with regular updates and improvements.
4. **Performance**: Mithril is known for its lightweight and efficient virtual DOM implementation, resulting in fast rendering and updates, whereas Apache Cordova can sometimes suffer from performance issues due to the overhead of bridging web code with native APIs.
5. **Learning Curve**: Mithril has a steeper learning curve compared to Apache Cordova, especially for developers new to functional programming paradigms and virtual DOM concepts, while Apache Cordova offers a more familiar development approach for web developers transitioning to mobile app development.
6. **Supported Platforms**: Apache Cordova supports a wide range of mobile platforms including iOS, Android, and Windows Phone, as well as desktop platforms like Windows, macOS, and Linux, while Mithril primarily focuses on web browsers and does not offer built-in support for native mobile platforms.
In Summary, Apache Cordova and Mithril differ in their architecture, build tools, community support, performance, learning curve, and supported platforms, catering to different needs in mobile and web application development.
I've done some Hybrid Mobile apps with both technologies Apache Cordova
and React Native
and described my experience in my blog.
In a few words, I would suggest to use each technology in accordance what what is your current code base and what do you want to achieve.
React Native is a great option if you need that extra edge in performance with multi-threading and native UI rendering. Or you already have a web app based on React which you want to port to mobile.
On the other hand, if you have an existing web application code and you want to reuse some or all, including the ability to use web third-party libraries, then Cordova is the best option.
Proguard
?
ProGuard is the most popular optimizer for Java bytecode. It makes your Java and Android applications up to 90% smaller and up to 20% faster. ProGuard also provides minimal protection against reverse engineering by obfuscating the names of classes, fields and methods.
How to use it inCordova
app?
I didn't find any plugins for it. So I've implemented it by myself and shared it on GitHub.
Feel free to use!
Pros of Apache Cordova
- Lots of plugins48
- JavaScript35
- Great community26
- Easy Development25
- Easy to learn18
- Cross platform15
- Open Source7
- Easy, fast, not buggy in my experience with my code6
- Lots of descendants; PhoneGap, Ionic, Intel XDA etc6
- Can use CSS34
- Rich HTML 54
- Easy debugging4
- HTML, CSS and JS3
- Fast and hot reload3
- Rich css ui3
- Use what you code in your browser3
- Need a light system2
- Native Web Technologies2
- Without extra tooling needed2
- One code base everywhere2
Pros of Mithril
- Lightweight16
- Faster than React12
- Pure JavaScript10
- Virtual Dom10
- Robust8
- Unopinionated7
- Works with ES67
- Very active development6
- Intelligent auto-redrawing system5
- Flux compatible3
- Small Learning Curve2
Sign up to add or upvote prosMake informed product decisions
Cons of Apache Cordova
- No native performance2
- Hard to install1
- Hard to install0
Cons of Mithril
- Virtual Dom1