Mai 5, 2017

Nativescript: Actionbar with Android Material Design Icons

Have you ever wondered how you can get a Action Bar like this one in Nativescript?

It’s easy:

I hope you have Android Studio preinstalled, you need it. Create and open a example Android Project with Android Studio.

Now Right-Click on your Project Folder, select   New -> Vector Asset which opens a new Dialog.

You can select the Icon you want and click Next. Note the path, where the file is saved.

In your NativeScript Project create a new folder App_Resource/Android/drawable, copy your xml file from your android project into this folder.

Now you can use the file in NativeScript:

Restart the build and give it a try.

 

Avatar-Foto

theCodeCampus
Developer at thecodecampus </>

Our knowledge is not simply gained through reading - it is trained, tested and constantly being expanded. Because first and foremost, we are all developers at W11K. The know-how that we acquire here as developers, consultants and information architects flows immediately into our training courses and articles for theCodeCampus.


Schreibe einen Kommentar

Add code to your comment in Markdown syntax.
Like this:
`inline example`

```
code block
example
```

Deine E-Mail-Adresse wird nicht veröffentlicht.