Skip to main content
Topic: SASS or LESS may be an option? (Read 5771 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Re: SASS or LESS may be an option?

Reply #15

I think you should do that with a plugin. Node.js has many libraries (gulp, webpack, etc) that handle this for people already. I'd just use webpack and watch the scss dir if I was developing. I wouldn't want to do it manually.

Re: SASS or LESS may be an option?

Reply #16

If you have a VPS you can do the way you want. :)
If you are on a shared, a button "compile" and a php library is likely the only thing that works (somehow) reliably.
Bugs creator.
Features destroyer.
Template killer.

Re: SASS or LESS may be an option?

Reply #17

Quote from: Joshua Dickerson – Any hope of coming back to this? I don't see how SCSS is any harder than CSS. I'd create a "colors.scss" file that would allow admins to change their colors. Just define a bunch of variables in there and use those variables around the SCSS. Then, you can pretty much get rid of this idea of "variants" (I never liked it). You just give someone your "colors file" and they can use any SCSS compiler online if they don't have one locally. You can create a plugin to do this in PHP inside Elk with scssphp!
What exactly is it you don't like about variants? Variants may be largely colors but just colors isn't even remotely the same thing at all. I think the theme variants and custom_blabla.css are quite elegant if there's no need to duplicate a theme completely; especially if the CSS is all you're going to change. However, overrides should preferably already be integrated while generating the minified CSS, as opposed to leaving the extra processing to the browser. And of course something like SCSS allows you to use variables in a backward-compatible manner.

So if you used colors file as a shorthand for overrides and additions,[1] never mind. But otherwise I'm fairly sure I've got some kind of objection. :)
Which would mostly consist of various colors, fonts, background images, and units of size, but could also include position, display, float, generated content, etc. All relatively minor things that can still hugely impact the general look and feel of a page.
Last Edit: May 05, 2017, 12:35:06 pm by Frenzie

Re: SASS or LESS may be an option?

Reply #18

Mediawiki uses LESS and its parsed when style sheets are combined and such.  Certainly makes minor changes easier...assuming variables are where you need them.

Re: SASS or LESS may be an option?

Reply #19

@Frenzie most people define their fonts in a file called "fonts" and their colors with the same name. I just used "colors" as an example. The idea of variants is that the structure stays the same and the skin changes, but it is a weird word. Most people use skin in the software industry.

Re: SASS or LESS may be an option?

Reply #20

@Joshua Dickerson But what exactly is it you dislike about the idea of variants? Is it just the name then?