So my question relates with how would I add CSS gradients to NativeScript?
I currently have an .xml file and a .js file for the mock visualization. All I can show is one standard color on my emulator now. Is there a way I could add gradients in the .css file itself or any other way where its possible to add gradients instead of hardcoding it into the app itself as the app I am working on would require different gradients on different pages.
Thanks!
So my question relates with how would I add CSS gradients to NativeScript?
I currently have an .xml file and a .js file for the mock visualization. All I can show is one standard color on my emulator now. Is there a way I could add gradients in the .css file itself or any other way where its possible to add gradients instead of hardcoding it into the app itself as the app I am working on would require different gradients on different pages.
Thanks!
Share Improve this question asked Apr 14, 2016 at 16:11 user4077377user40773771 Answer
Reset to default 6Update : NativeScript 4.x and above is now supporting linear-gradient. An example can be seen in this documentation article
Wele to StackOverflow and NativeScript! Curr,ently CSS-gradients are future feature for {N}. However, you can implement them using the native code for Android and iOS.
Good linear gradient sample implementations for both platforms are shown in this discussion : https://github./NativeScript/NativeScript/issues/539