• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

As designed Cannot reference certain style properties

Mike

XenForo developer
Staff member
#3
This is removed intentionally (compileCssProperty_cleanUp method in the style property model), mostly to reduce memory usage (as the style property cache is already fairly large and people often have multiple styles. Properties that we considered unlikely to be used independently are not exposed to the cache.

This was not possible in 1.1 (I didn't check 1.0 though).
 

Mike Creuzer

Well-known member
#4
Thanks for the answer. Not the right place to ask, perhaps, but is the CSS cached or are the variables themselves? I thought it was the CSS that was recached everytime you save the template. If so, couldn't you reference as many variables as you wanted? Just curious.
 

Mike

XenForo developer
Staff member
#5
The property values are not cached in the CSS. (They are a template syntax so they are resolved live as needed.)
 

Mike Creuzer

Well-known member
#6
The property values are not cached in the CSS. (They are a template syntax so they are resolved live as needed.)
Would it make sense to do so? I thought on template save, it takes that code, parses all the xenforo syntax, and outputs raw html/css which is then cached. The cached file is whats served. Updating a template updates the cache. Is that not accurate? It would seem then that all the caching is done in the backend so you could then use how many variables you wanted.

I by no means understand how this process works, just trying to so I am curious. Sorry if this doesn't make sense.