This project is read-only.

Theme dependent on specific module?

Topics: Troubleshooting, Writing themes
Mar 7, 2011 at 8:51 PM
Edited Mar 7, 2011 at 8:53 PM


Can the theme be dependent on a specific module? So that when the theme gets enabled that module would be enabled (and downloaded from gallery when cooking recipe, if needed) too? It works for modules, and I'm not sure if it works for themes though. I know that the "BaseTheme" manifest property means basically the same as "Dependencies" for features, but I don't know if it would work if I'd specify a module/feature instead of a theme there?

I use some functionality from another non-core module in my theme, that's why it needs to have a dependency.

And BTW - could you create a docs article describing the manifest files (module.txt and theme.txt) in greater detail? Their syntax, how they are being processed, common problems (I could add sth to this section though;) etc. What do you think, Team?

- Piotr

Mar 7, 2011 at 9:19 PM

Yes, themes are like modules, and you can also provide a csproj if you want for them. Just add some dependecies and they will be enabled.

Mar 7, 2011 at 9:22 PM

Thanks! But how to do that?:) Should I add a "Features:" section in the Theme.txt manifest file and add dependencies there?

Mar 7, 2011 at 9:39 PM


Mar 8, 2011 at 12:33 AM

Did that and didn't work - the module is still disabled. My steps:

  1. Created a simple theme via codegen
  2. Added the "Features:" section to the Theme.txt
  3. Added the "Dependencies: " line (and also the other three) and my module full name
  4. Enabled my theme via Set Current.
  5. The module specified in dependencies is still disabled:/