Questions tagged [stylus-loader]

A stylus (the stylesheet preprocessor) loader for webpack.

Has two flavors: for webpack 2 and 4. Many questions are about migration issues.

https://github.com/shama/stylus-loader

12 questions
8
votes
3 answers

Change default font in vuetify is not working (vue-cli 3) [Vuetify 1.X]

I'm aware of the question change-default-font-in-vuetify in SO, but it doesn't address my problem as it was posted before vue-cli-3 came out, so the ideas there don't apply here as that, the official docs from Vuetify on how to change themes and…
sab
  • 1,454
  • 1
  • 14
  • 26
3
votes
0 answers

Resolve stylus import file from webpack's resolve directory (absolute path)

Versions: stylus: 0.54.5 stylus-loader: 3.0.2 webpack: 4.30.0 Folder structure: src |_ css |_ base |_ _vars.styl |_ another.styl |_ js |_ some |_ some.js => (It has "import './some.styl'") |_ some.styl import…
master_dodo
  • 1,203
  • 3
  • 20
  • 31
2
votes
1 answer

Compiling Stylus with Webpack 4 without importing it into a JS file?

Something like this: var stylusCompiler = { name: 'stylus', entry: { above_fold: './src/css/above_fold.styl', site: './src/css/site.styl' }, output: { path: path.resolve(__dirname, 'dist/css'), …
Joren
  • 9,623
  • 19
  • 63
  • 104
2
votes
2 answers

How to add css-loader and stylus-loader into nuxt.config.js?

I create an Nuxt.js skeleton: yarn create nuxt-app myapp Then I add css-loader and stylus loader: yarn add css-loader yarn add stylus stylus loader I then add them to nuxt.config.js: build: { /* ** You can extend webpack config here …
Billal Begueradj
  • 20,717
  • 43
  • 112
  • 130
1
vote
0 answers

How to import a global Stylus file in Vue.js

I want to use it for my global variables. The fila I want to import just has this single line: primary = red But i can't import the file globally. I tried in vue.config.js (_variables.styl is in the same folter, to avoid the route as an error…
0
votes
0 answers

Stylus files not compiling in Storybook, Stylus package return AST tree instead of CSS

I'm trying to setup Storybook for the shared components library which uses stylus. And this is what I'm getting after running npm run build-storybook ERR! => Failed to build the preview ERR! Module build failed (from…
0
votes
0 answers

Webpack - vue, babel, stylus, pug config issues

My project has the following structure: two types of components, vue and folder with pug/js/styl; index.pug is the main file that is to be index.html and index.pug extends layout and includes other pug, like head.pug that has the main.js script with…
CodeGust
  • 831
  • 3
  • 15
  • 36
0
votes
0 answers

Can't automatically import Stylus file to VueJS project

For the past 2 days, I've been trying to figure out how to import a global stylus file into all of my components so that I don't end up with `@import '../../../styles.styl' in each component or ever need to adjust that. I've used the configuration…
musicfiend122
  • 23
  • 2
  • 7
0
votes
0 answers

global import stylus once in vuejs

My stylus global file is imported multiple times. How import global stylus in vue? my vue.config.js module.exports = { css: { loaderOptions: { stylus: { import: [ '~@/assets/stylus/reset.styl', …
user7895148
0
votes
0 answers

Use Stylus for NativeScript Vue?

I've set up a sample NativeScript Vue project as per the quick start guide. Additionally, I installed the Stylus plugin with tns install stylus. However, it doesn't seem to recognise the Stylus code in the Vue single-file…
0
votes
1 answer

cant load .styl with webpack override

I am using react-app-rewired and want to use .styl as css. The issue that I tried to add some plugin in order to use .styl inside my components with react. file name:config-overrides.js var stylus_plugin = require('stylus_plugin'); …
Vitaly Menchikovsky
  • 7,684
  • 17
  • 57
  • 89