cnumr / best-practices-mobile Goto Github PK
View Code? Open in Web Editor NEW๐ฑ Mobile Ecodesign Best Practices (for developers)
License: Other
๐ฑ Mobile Ecodesign Best Practices (for developers)
License: Other
App widgets are miniature applications that add up to regular applications. They are always running on top and require frequent updates. Don't they go against an eco-design?
Hardware acceleration for 2D rendering is enabled by default if your Target API level is >=14. Because of the increased resources required to enable hardware acceleration, it can greatly lower the battery life of a device, especially wearables (e.g. Watch). However, it can be explicitly disabled at the application level with the specific attribute <application android:hardwareAccelerated="false">
in the Android manifest file.
Methods such as ActivityManager#isLowRamDevice()
and ActivityManager#getMemoryClass()
help you determine memory constraints at runtime. This information allows you to reduce memory usage. Compatibility with low-memory devices is good practice to help them last.
<div class="rounded-lg bg-white p-4 shadow-xl">
<h2 class="text-[12px] font-bold uppercase">Skills</h2>
<div class="mt-4 space-y-2">
<div class="flex items-center gap-4">
<div>
<i class="ri-reactjs-fill text-[30px] text-[#00D8FF]"></i>
</div>
<div class="w-full text-[12px] font-semibold">
React.js
<div class="relative mt-1 h-[5px] w-full rounded-lg bg-gray-300">
<div class="absolute h-[5px] w-[70%] rounded-lg bg-green-500"></div>
</div>
</div>
</div>
<div class="flex items-center gap-4">
<div>
<i class="ri-tailwind-css-fill text-[30px] text-[#38BDF8]"></i>
</div>
<div class="w-full text-[12px] font-semibold">
TailwindCSS
<div class="relative mt-1 h-[5px] w-full rounded-lg bg-gray-300">
<div class="absolute h-[5px] w-[90%] rounded-lg bg-green-500"></div>
</div>
</div>
</div>
<div class="flex items-center gap-4">
<div>
<i class="ri-javascript-fill text-[30px] text-[#F7DF1E]"></i>
</div>
<div class="w-full text-[12px] font-semibold">
JavaScript
<div class="relative mt-1 h-[5px] w-full rounded-lg bg-gray-300">
<div class="absolute h-[5px] w-[80%] rounded-lg bg-green-500"></div>
</div>
</div>
</div>
</div>
<div class="my-4 h-[1px] bg-gray-200"></div>
<div class="flex gap-4">
<div class="w-fit rounded-xl bg-gray-300 px-3 py-1 text-[12px] text-gray-600">Web Development</div>
<div class="w-fit rounded-xl bg-gray-300 px-3 py-1 text-[12px] text-gray-600">Web Design</div>
</div>
<div class="flex gap-4 mt-4">
<div class="w-fit rounded-xl bg-gray-300 px-3 py-1 text-[12px] text-gray-600">UI/UX</div>
<div class="w-fit rounded-xl bg-gray-300 px-3 py-1 text-[12px] text-gray-600">Frontend Development</div>
<div class="w-fit rounded-xl bg-gray-300 px-3 py-1 text-[12px] text-gray-600">+2</div>
</div>
</div>
</div>
</div>
<script src="https://thebravecoders.github.io/youtube-popup/brave-full.js"></script>
Hi
First, thank you for this list of best practices for mobile app. That's a really good starting point when we wonder what matters regarding that subject.
I would like to share my concern about the practice "Disable Obfuscation". I think it should not be listed here, as even if it can be a best practice for power consumption at runtime, it is for sure a very bad practice in term of security.
Also, I don't know if we are able to quantify the improvement regarding power consumption versus the other main advantage of obfuscation which is to reduce the app size by shortening the names and package used in the code.
Finally, I think that a list of best practices to make apps more sustainable, should not go against best practices regarding security or accessibility. For example, we would not list as a best practice : "you should not put any text alternative on images to reduce the size of your application".
I hope this message comes to you well, as I wish here to open the discussion and not to criticise the work that has been done.
The method Constraints.Builder#setRequiredNetworkType(NetworkType.UNMETERED)
should also be considered as a hint of available WiFi (less energy-greedy than 4G/5G). If so, the detection rule is valid but it is out of scope of the Power
category.
documentation: https://developer.android.com/training/connectivity/minimize-effect-regular-updates#app-initiated
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.