Vuepress: theme-default should support all pre-processor

Created on 17 Dec 2018  路  5Comments  路  Source: vuejs/vuepress


Feature request

Hi,
I extended theme-default with custom components.
Those components are SFC using scss as the pre-processor.
The issue is that I can't access variables i created in palette.styl.
If i rename palette.styl in palette.scss, theme-default ignore the file.
Same goes for index.styl.
Shouldn't the theme load the correct file depending on the user configuration ?



What problem does this feature solve?

This would let the user use his prefered pre-processor.
SASS/SCSS is far more popular than Stylus.

What does the proposed API look like?

How should this be implemented in your opinion?

Are you willing to work on this yourself?**

Most helpful comment

Is there a specific reason why you choose stylus instead of the more popular scss/sass ?

All 5 comments

You can't mix and match stylus and scss (at least not in terms of variable access). And since the default theme uses stylus you need to use that when you extend the theme and want to access stylus defined variables.

You are free to use SASS/SCSS if you start from scratch with your own theme, though.

Then, could we use css custom propriety (css-vars) for variables so they are available in both or that wouldn't work either ?

As said, I was able to use SCSS in my vue component, but since the default theme use stylus, there is no way to access the theme color.

Is there a specific reason why you choose stylus instead of the more popular scss/sass ?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

sankincn picture sankincn  路  3Comments

harryhorton picture harryhorton  路  3Comments

gaomd picture gaomd  路  3Comments

alinnert picture alinnert  路  3Comments

zeke picture zeke  路  3Comments