How can use a custom theme for my application


#1

Hi there,

I bought an ionic theme, its name is Musicana. But how can use that? I tried copy all files to www directory, but when I start app again src files override my template.

Thanks for your hepls.

Here is the files include in theme’s folder


#2

Contact your seller. All items in the www folder are overwritten with each new build (ie ionic serve).

It varies if you are developing Ionic 1 or new Ionic as to the files locations.


#3

Thanks for your answer. I sent an email to seller. I am developing on Ionic 2, theme just includes www files, there is no files like src files.

Can just seller help me?


#4

See: https://robferguson.org/blog/2017/11/12/theming-your-ionic-3-app/


#5

Hi, thanks for your answer. I can theming an app, but I need use a purchased theme. That has no elements like src items, just have html, css and angular files like www directory’s files.


#6

If its a theme then it should have some .scss files?

If it has .css files see: https://ionicacademy.com/ionic-include-css-files-from-npm/


#7

I inserted a capture from theme’s directory by edit question. You can look, I’m afraid it’s only an html design… But thanks for your answer.

edit: I forgot to say I looked link, it doesn’t see to help me. I think I can’t compile all files with a config.json :confused: but if you think “yes you can” I am glad to hear your ideas


#8

What’s in the /lib/ionic/scss folder?

 - lib
   - ionic
      - scss

#9

Here is the capture


#10

Ok, so you have the theme’s .scss files you just need to add them to your project.

For example, update variables.scss as follows:

...

// App Theme
// --------------------------------------------------

@import "ionic.theme.default";

@import "./_action-sheet.scss";
...

Then apply the theme's styles to your templates.


#11

Ok, thank you I will try :slight_smile: I bought wrong version, it was for Ionic 1.3.x :confused: