question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

How do I apply a smallIcon?

See original GitHub issue

Hello,

I’m quite clueless how I do include a smallIcon. I have been prompted that I need to use a “res://…” path.

But it appears that I have no Idea around that. And just stubbornly use

smallIcon: "res://path/to/icon/in/www or smallIcon: "res://path/to/icon/in/www/without/www

Does not do the trick. And I assume that naive attempt is pretty newbish because I’m missing out on what “res://” actually means.

So I’m there on the journey what this res:// actually is and how I can but ressources in there through cordova. Maybe somebody here knows how I should treat it?

I’m already researching about it - until yet it only confused me, appears I need to completely figure out how Cordova moves assets for iOS and Android during build which is quite a task 😕

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:10

github_iconTop GitHub Comments

1reaction
JhonnyJasoncommented, Jun 20, 2018

Yet I have found the folder on my system where to I have put the ressources in: platforms/android/app/src/main/res

When I include the icons notification.png of size 18x18 to drawable-ldpi-v11 24x24 to drawable-mdpi-v11 36x36 to drawable-hdpi-v11 48x48 to drawable-xhdpi-v11

It finally builds and works yey! 😄

Now I can automate that with such a hook-script as inspired by @rwillett thnx!

And hope that for iOS it just works^^

0reactions
J4si3kcommented, May 16, 2019

Thank you @JhonnyJason for your answer. This really help me! All my day i try to set smallIcon on android and finally i did this! I’m using this plugin with Meteor! What is important in my case that:

  • file name should be other then icon.png, i use notification.png
  • set correct png file, look here
  • set property like this: smallIcon: 'notification'
Read more comments on GitHub >

github_iconTop Results From Across the Web

How to set default smallIcon and largeIcon in an Android ...
In Android Studio, go to File -> New -> Image Asset . Then, choose Notification Icon . Now customize your new small Icon...
Read more >
Android: Notification Icons - OneSignal Documentation
You may add a default icon that appears with every notification you send, ... The small icon is displayed on the top status...
Read more >
How to Put a Small Icon of Internet Explorer on ... - YouTube
Internet & Tech Tips. How to Put a Small Icon of Internet Explorer on Computer Toolbar : Internet & Tech Tips. 2.4K views...
Read more >
Android: how to add a small icon with a expo managed app ...
hello, I would like to know how can I provide a small icon for android using expo managed with eas build and the...
Read more >
How to set Large icon instead of small icon on Android ...
Step 2 − Add the following code to res/layout/activity_main.xml. <? xml version = "1.0" encoding = ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found