Tag Archives: #GoogleIO

Mercari improves UI development productivity by 56% with Jetpack Compose

Posted by Chiko Shimizu, Partner Developer Advocate and Tamao Imura, Developer Marketing Manager

Mercari improves UI development productivity by 56% with Jetpack Compose

Mercari allows millions of people to shop and sell almost anything. The company was founded in 2013 in Japan, and it now is the largest smartphone-focused C2C marketplace in Japan. Mercari’s Client Architect Team started using Jetpack Compose in 2020 with the goal of using modern solutions and technologies that can scale for the long term to build their tech stack for new applications.

What they did

The Mercari team needed to implement a design system with complex state management and styling on Android Views — a very complex task. Using Jetpack Compose, they were not only able to implement this complex system, it helped them spend less time developing each screen.

Jetpack Compose also helped the team write UI code for their new app utilizing the design system, making their UI code concise and easy to understand. As a result, the team can spend more time writing screens and business logic, such as practical support for the dark theme.

In addition, the Mercari team wrote a proof-of-concept tool for integrating Figma with the design system, which automatically generates UI code from the component designs. The team said that developing this tool was easier with Compose due to its declarative nature.

“Once Android developers get used to writing Jetpack Compose code, they wouldn’t wish to go back.” - Anthony Allan Conda, Android Tech Lead at Mercari

Results

Between Jetpack Compose and their new design system, Mercari was able to use far less code to write screens. On screens with infinitely-scrollable content — a common use case — they actually reduced their code by about 56%. As a result, they were able to write more screens in the same amount of time, giving them more time to write business logic and other parts of the code.

Also, they were able to do more with the UI itself, such as incorporating animations and using intuitive APIs such as AnimatedVisibility, Crossfade, and Animatable.

Mercari is planning to continue using Jetpack Compose in their new application until its release. Their design system, with the Android SDK written in Jetpack Compose, is also designed to work with multiple applications within Mercari.

Get started

Learn more about Jetpack Compose.

The top Google Play updates from I/O ‘21

Posted by Alex Musil, Director of Product, Google Play

This year, we announced many great new features, tools, and updates to help you make the most of Google Play. You can check out all the updates in our I/O session, or keep reading for a quick overview of the new capabilities that will help take your business even further, from driving more installs to growing your engagement and revenue.

15% service fee for the first $1M in earnings

1. Earlier this year, we announced an additional service fee tier to help boost developer success on Google Play. Starting July 1st, the service fee will be 15% instead of 30% for your first $1M (USD) of earnings each year. You’ll be able to enroll for the new rate in Play Console the week of June 7th, so we’re sharing details about the process now to give you time to get ready.

New tools for managing policy compliance

2. We’ve built a new, dedicated Policy and Programs section in Play Console to provide you with a centralized place to see any policy compliance concerns, guidance on how to fix policy issues, and information about upcoming policy changes.

More SDK guidance

3. The new Google Play SDK Console lets providers report issues with their SDK versions so we can give you better guidance and recommendations. We’ve started with several large SDK providers and will continue to add more.

4. Later this year, we’re launching a new, public website with important insights about popular SDKs to help you choose the right SDK for your app. Learn more about how we’re helping you build safer and more stable apps in the I/O session below.

Helping more users discover your apps and games

5. To ensure that your store listing assets can help users anticipate your in-app or in-game experience and drive meaningful downloads, we’re pre-announcing a policy change for app metadata...

6. and introducing new guidelines on store listing preview assets.

Distribution features for the future of publishing

7. One million apps are in production using the Android App Bundle, with 15% size savings on average vs a universal APK. The app bundle is the future of publishing on Google Play and, starting August 1, 2021, they’ll be required for all new apps.

8. Based on developer feedback, we'll soon be launching an optional code transparency feature to offer additional cryptographic assurance that your app’s code on device has not been modified from its original version.

Identify growth opportunities with our new competitive insights

9. To help you understand your engagement and monetization trends and optimize your product plans, we’ve taken the best of our ecosystem data and contextualized your performance against peersets. Learn how to make the most of them in the I/O session below.

10. You can now also customize and pin the precise metrics that matter to you in a personalized KPIs section at the top of your app dashboard.

More features for a flexible monetization strategy

11. Your global reach just got even larger: In 2020, we added 34 new local forms of payment across 30 markets around the world.

12. We lowered the minimum prices developers can set for paid apps, in-app purchases, and subscriptions in 20 new markets across Latin America, EMEA, and APAC.

13. This year, we’ll be launching multi-quantity purchases, which will allow your users to buy more than one item at a time from the cart.

14. We’ll also be launching multi-line subscriptions, which will allow you to sell multiple products as part of a single subscription.

15. And finally, we’ll be launching prepaid plans, which will let you offer users access to content for a fixed amount of time. (Don’t worry, users can easily extend at any time.)

16. Want to take advantage of these new features? Many will be available when you integrate Play Billing Library version 4.0, and more will be rolling out later this year. As a reminder, new apps are required to integrate version 3.0 by August 2, 2021 or by November 1, 2021 for updates to existing apps.

Program enhancements to engage and retain users

17. This year, Google Play Pass expanded to over 40 markets, with more than 800 games and apps. Developers have on average more than doubled their Play revenue across participating titles in these markets. Let us know if you’d like to join!

18. Google Play Points expanded to 22 countries and added deeper integration with Play Console making it even easier for developers to onboard. Play’s loyalty program helps developers increase engagement and reduce churn with their most high value users. Developers can learn more about joining the program here.

More educational content

19. Want to learn more about any of these features? We’ve built a comprehensive website with best practices and resources to help you learn more about our programs and tools.

20. Last but not least, we’ve also added tons of new free courses to Google Play Academy. Whether you're about to launch your startup or grow your existing business on Play, Google Play Academy has you covered.

How useful did you find this blog post?

What’s new for Android developers at Google I/O

Posted by Karen Ng, Director, Product Management & Jacob Lehrbaum, Director of Developer Relations, Android & Play

As Android developers, we are all driven by building experiences that delight people around the world. And with people depending on your apps more than ever, expectations are higher and your jobs as developers aren’t getting easier. Today, at Google I/O, we covered a few ways that we’re trying to help out, whether it be through Android 12 - one of the biggest design changes ever, Jetpack, Jetpack Compose, Android Studio, and Kotlin to help you build beautiful high quality apps. We’re also helping when it comes to extending your apps wherever your users go, like through wearables and larger-screened devices. You can watch the full Developer Keynote, but here are a few highlights:

Android 12: one of the biggest design updates ever.

The first Beta of Android 12 just started rolling out, and it’s packed with lots of cool stuff. From new user safety features like permissions for bluetooth and approximate location, enhancements to performance like expedited jobs and start up animations, to delightful experiences with more interactive widgets and stretch overscrolling, this release is one of the biggest design updates to Android ever. You can read more about what’s in Android 12 Beta 1 here, so you can start preparing your apps for the consumer release coming out later this year. Download the Beta and try it with your apps today!

Android 12 visual

Jetpack Compose: get ready for 1.0 in July!

For the last few years, we’ve been hard at work modernizing the Android development experience, listening to your feedback to keep the openness–a hallmark of Android, but becoming more opinionated about the right way to do things. You can see this throughout, from Android Studio, a performant IDE that can keep up with you, to Kotlin, a programming language that enables you to do more with less code, to Jetpack libraries that solve the hardest problems on mobile with backward compatibility.

The next step in this offering is Jetpack Compose - our modern UI toolkit to easily build beautiful apps for all Android devices. We announced Compose here at Google I/O two years ago and since then have been building it in the open, listening to your feedback to make sure we got it right. With the Compose Beta earlier this year, developers around the world have created some truly beautiful, innovative experiences in half the time, and the response to the #AndroidDevChallenge blew our socks off!

With the forthcoming update of Material You (which you can read more about here), we’ll be adding new Material components as well as further support for building for large screens, making it fast and easy to build a gorgeous UI. We’re pressure testing the final bits in Compose and will release 1.0 Stable in July—so get ready!

Android Studio Arctic Fox: Design, Devices, & Developer Productivity!

Android Studio Arctic Fox (2020.3.1) Beta, the latest release of the official powerful Android IDE, is out today to help you build quality apps easier and faster. We have delivered and updated the suite of tools to empower three major themes: accelerate your UI design, extend your app to new devices, and boost your developer productivity. With this latest release you can create modern UIs with Compose tooling, see test results across multiple devices, and optimize debugging databases and background tasks with the App Inspector. We’re also making your apps more accessible with the Accessibility Scanner and more performant with Memory Profiler. And for faster build speeds, we have the Android Gradle plugin 7.0, new DSL, and variant APIs. You can learn more about the Android Studio updates here.

Android Studio Arctic Fox

Kotlin: the most used language by professional Android devs

Kotlin is now the most used primary language by professional Android developers according to our recent surveys; in fact, over 1.2M apps in the Play Store use Kotlin, including 80% of the top 1000 apps. And here at Google, we love it too: 70+ Google apps like Drive, Home, Maps and Play use Kotlin. And with a brand-new native solution to annotation processing for Kotlin built from the ground up, Kotlin Symbol Processing is available today, a powerful and yet simple API for parsing Kotlin code directly, showing speeds up to 2x faster with libraries like Room.

Android Jetpack: write features, not boilerplate

With Android Jetpack, we built a suite of libraries to help reduce boilerplate code so you can focus on the code you care about. Over 84% of the top 10,000 apps are now using a Jetpack library. And today, we’re unpacking some new releases for Jetpack, including Jetpack Macrobenchmark (Alpha) to capture large interactions that affect your app startup and jank before your app is released, as well as a new Kotlin Coroutines API for persisting data more efficiently via Jetpack DataStore (Beta). You can read about all the updates in Android Jetpack here.

Now is the time: a big step for Wear

The best thing about modern Android development is that these tools have been purpose built to help make it easy for you to build for the next era of Android, which is all about enabling devices connected to your phone–TVs, cars, watches, tablets–to work better together.

Starting today, we take a huge step forward with wearables. First, we introduced a unified platform built jointly with Samsung, combining the best of Wear and Tizen. Second, we shared a new consumer experience with revamped Google apps. And third, a world-class health and fitness service from Fitbit is coming to the platform. As an Android developer, it means you’ll have more reach, and you’ll be able to use all of your existing skills, tools, and APIs that make your mobile apps great, to build for a single wearables platform used by people all over the world.

Whether it’s new Jetpack APIs for Wear tailored for small screens and designed to optimize battery life, to the Jetpack Tiles API, so you can create a custom Tile for all the devices in the Wear ecosystem, there are a number of new features to help you build on Wear. And with a new set of APIs for Health and Fitness, created in collaboration with Samsung, data collection from sensors and metrics computation is streamlined, consistent, and accurate–like heart rate to calories to daily distance–from one trusted source. All this comes together in new tooling, with the release of Android Studio Arctic Fox Beta, like easier pairing to test apps, and even a virtual heart rate sensor in the emulator. And when your app is ready, users will have a much easier time discovering the world of Wear apps on Google Play, with some big updates to discoverability. You can read more about all of the Wear updates here.

Tapping the momentum of larger screens, like tablets, Chrome OS and foldables

When it comes to larger screens -- tablets, foldables, and Chrome OS laptops-- there is huge momentum. People are increasingly relying on large screen devices to stay connected with family and friends, go to school, or work remotely. In fact, there are over 250 million active large screen Android devices. Last year, Chrome OS grew +92% year over year–5 times the rate of the PC market, making Chrome OS the fastest growing and the second-most popular desktop OS. To help you take advantage of this momentum, we’re giving you APIs and tools to make optimizing that experience easier: like having your content resize automatically to more space by using SlidingpaneLayout 1.2.0 and a new vertical navigation rail component, Max widths on components to avoid stretched UIs, as well as updates to the platform, Chrome OS, and Jetpack windowmanager, so apps work better by default. You can learn more here.

Google Duo's optimized experience for foldable devices

Google Duo's optimized experience for foldable devices

This is just a taste of some of the new ways we’re making it easier for you to build high quality Android apps. Later today, we’ll be releasing more than 20 technical sessions on Android and Play, covering a wide range of topics such as background tasks, privacy, and Machine Learning on Android, or the top 12 tips to get you ready for Android 12. If building for cars, TVs, and wearables is your thing, we got that covered, too. You can find all these sessions - and more - on the I/O website. Beyond the sessions and news, there’s a number of fun ways to virtually connect with Googlers and other developers at this year’s Google I/O. You can check out the Android dome in I/O Adventure, where you can see new blog posts, videos, codelabs, and more. Maybe even test out your Jetpack Compose skills or take a virtual tour of the cars inside our dome!

What’s new in Android 12 Beta

Posted by Dave Burke, VP of Engineering

Android 12 logo

Today at Google I/O we unveiled the first Beta of Android 12, one of our most ambitious releases ever. We focused on a new UI that adapts to you, improving performance, with privacy and security at the core. For developers, we’re giving you more tools to build delightful experiences for people on phones, laptops, tablets, wearables, TVs, and cars.

There’s a lot to explore in Beta 1, starting with the most significant UI update to Android yet, created with a design language that we call Material You. There are new privacy features to try too, like approximate location, and a new standard called Performance Class that lets apps and users identify high-performing devices.

Try Android 12 Beta today on Pixel devices by enrolling here. Thanks to our device-maker partners who are working to accelerate updates, you can now get the Beta on other devices as well, including select devices from ASUS, OnePlus, Oppo, Realme, Sharp, TCL, Transsion, Vivo, Xiaomi, and ZTE, with others on the way. Visit android.com/beta to learn more.

Read on for more highlights of what’s new and visit the Android 12 developer site for details on everything in Android 12 and how to get started developing.

A new UI for Android

As we highlighted in our consumer blog post, Android 12 brings the biggest design change in Android's history. We rethought the entire experience, from the colors to the shapes, light and motion, making Android 12 more expressive, dynamic, and personal. This work is being done in deep collaboration between our software, hardware and Material Design teams, and we’re unifying our software and hardware ecosystems under a single design language called Material You.

Android 12 UI

We’ve extended the new design language across the platform and UI components, so your apps will get these upgrades automatically.

Redesigned widgets - Along with the design changes in Android 12 we’ve refreshed app widgets to make them more useful, beautiful, and discoverable. We added new interactive controls like checkboxes, switches, and radio buttons and made personalizing widgets easier. Android 12 widgets look great with our system UI and themes, with rounded corners and padding automatically adapted to every launcher and home screen. Responsive layouts let you adapt widgets to phones, tablets, foldables, and other screens. We also added dynamic color APIs so your widgets can use system colors to create a personalized but consistent look. And we’re making widgets easier to discover through an improved widget picker and an integration with the Assistant. Check out sample code and give the updated widgets a try. More here.

widgets in Android 12

Stretch overscroll - We’re also adding a new system-wide “stretch” overscroll effect to let users know they’ve scrolled past the end of the available content in your UI. The stretch effect provides a natural vertical and horizontal scroll-stop indicator that’s common across all apps, and it’s enabled by default for scrolling containers across the platform and AndroidX. The new stretch overscroll replaces the glow overscroll supported in previous versions. Make sure to test your apps and content with the new scrolling behavior, and if needed you can opt out. More here.

Smoother audio transitions - UI isn't just about the visuals. We've also improved the way that audio focus is handled. When an app loses audio focus, its audio is automatically faded out, providing a smoother transition between apps which play audio, and preventing apps from playing over each other. This is particularly relevant in foldable and multi-screen Android environments. More here.

Performance

With Android 12, we’ve made significant and deep investments in performance - from foundational performance that makes the system and apps faster and smoother, to a new standard for high-performing devices that helps developers deliver richer experiences on those devices.

Faster, more efficient system performance - We reduced the CPU time needed for core system services by 22%, so devices will be faster and more responsive. We also improved Android's power efficiency by reducing the use of big cores by the system server by 15% to help devices run longer before needing to charge.

Sampled rate , omn big core

We improved transitions and app startup times by reducing lock contention and latency variability, and we optimized I/O for faster app loading. In PackageManager, a read-only snapshot reduced lock contention by as much as 92%. In Binder, lightweight caching radically improved latencies up to 47x in targeted calls. In I/O, we accelerated dex/odex/vdex files to improve app load times, especially on low-memory phones. Our restriction on notification trampolines also helps reduce latency for apps started from a notification. For example, the Google Photos app now launches 34% faster after moving away from notification trampolines.

To improve database query performance we’ve optimized CursorWindow by inlining results in Binder transactions. For small windows, CursorWindow is 36% faster, and for windows over 1000 rows the improvements are as high as 49x.

Performance class - Starting with Android 12 and working together with our ecosystem partners, we’re introducing a common standard for high-performing Android devices.

This standard, called performance class, defines a set of capabilities that go beyond Android's baseline requirements. Devices that meet the performance class requirements can support more demanding use-cases and deliver higher quality content. Developers can check for performance class at runtime and then reliably deliver enhanced experiences that take full advantage of the device’s performance.

Initially, we’re focusing performance class capabilities on media use-cases, with requirements including camera startup latency, codec availability and encoding quality, as well as minimum memory size, screen resolution and read/write performance. More here.

Private by design

Privacy is at the heart of everything we do, and in Android 12 we’re continuing to give people more transparency and control while keeping their devices and data secure. Today we announced several new privacy features that will be coming in Beta 2 - Privacy Dashboard, microphone and camera indicators, and microphone and camera toggles. Stay tuned for more on these features. Here’s what’s new in Beta 1.

App hibernation - Last year we launched permissions auto-reset, and over the last two weeks, Android has reset permissions for over 8.5 million apps that weren’t being used - so apps that people have forgotten about can’t still access their data. In Android 12 we’re building on permissions auto-reset by intelligently hibernating apps that have gone unused for an extended period - optimizing for device storage, performance and safety. Hibernation not only revokes permissions granted previously by the user, but it also force-stops the app and reclaims memory, storage and other temporary resources. In this state the system also prevents apps from running jobs in the background or receiving push notifications, helping to keep users safe. Hibernation should be transparent for most apps, but if needed, direct users to Settings to turn off this feature for your app. More here.

Android 12 device location

Nearby device permissions - Previously, Bluetooth scanning required apps to have the location permission, which was a challenge for apps that needed to pair with nearby devices but didn’t actually need the device location. We’re now allowing apps to scan for nearby devices without needing location permission. Apps targeting Android 12 can scan using the new BLUETOOTH_SCAN permission with the usesPermissionFlags="neverForLocation" attribute. After pairing with a device, use the BLUETOOTH_CONNECT permission to interact with it. These permissions promote privacy-friendly app design while reducing friction for apps. More here.

Approximate location - Recently we’ve given people better ways to manage access to location, such as through separate permissions for foreground and background access and an “only this time” option. Now for apps targeting Android 12, we’re offering even more control with a new “approximate location” option. When apps request precise location data, users can now choose to grant either precise or approximate location. Users can also change an app’s location precision at any time from Settings. If your app requests precise location data (ACCESS_FINE_LOCATION), keep these changes in mind and make sure your app functions properly with approximate location only. For almost all general uses of location, we recommend asking for approximate location (ACCESS_COARSE_LOCATION) only. More here.

App compatibility

If you haven’t tested your app for compatibility with Android 12 yet, now is the time to do it! With Android 12 in Beta, we’re opening up access to early-adopter users as well as developers, on Pixel and other devices. This means that in the weeks ahead, expect many more users to be trying your app on Android 12 and raising any issues that they find.

To test for compatibility, install your published app from Google Play or other source on a device or emulator running Android 12 Beta and work through all of the app’s flows. Review the behavior changes to focus your testing. After you’ve resolved any issues, publish an update as soon as possible.

With Beta we’re getting closer to Platform Stability in August 2021. Starting then, app-facing system behaviors, SDK/NDK APIs, and non-SDK lists will be finalized. At that time, finish up your final compatibility testing and release a fully compatible version of your app, SDK, or library. More on the timeline for developers is here.

timeline

Get started with Android 12!

Today’s Beta release has everything you need to try the Android 12 features, test your apps, and give us feedback. Just enroll any supported Pixel device here to get the update over-the-air. If you’ve already installed a preview build, you’ll automatically get Beta updates. To get started developing, set up the SDK.

You can also get Android 12 Beta on devices from some of our top device-maker partners who are participating in the Android 12 Developer Preview program. Visit android.com/beta to see the full list of partners, with links to their sites with details on their supported devices. Each partner will handle their own enrollments and support, and provide the Beta updates to you directly.

For even broader testing on supported devices, try Android 12 Beta on Android GSI images, and if you don’t have a device you can test on the Android Emulator -- just download the latest emulator system images via the SDK Manager in Android Studio.

For complete details on how to get the Beta, visit the Android 12 developer site.