Vuetify: [Bug Report] Extending component gives errors

Created on 6 Dec 2017  路  7Comments  路  Source: vuetifyjs/vuetify

Versions and Environment

Vuetify: 0.17.4
Vue: 2.5.0
Browsers: Chrome 61.0.3163.100
OS: Mac OS 10.12.5

Steps to reproduce

Importing a component like this

import DataTable from 'vuetify/src/components/VDataTable/VDataTable'

Raises styl errors.

These relative modules were not found:
../../stylus/components/_progress-linear.styl in ./~/vuetify/src/components/VProgressLinear/VProgressLinear.js

Expected Behavior

That a component could be extended.

Actual Behavior

It's not actually extending and is raising errors.

Reproduction Link

https://codesandbox.io/s/1418jky5q4

Other comments

The reproduction link has a similar styl error, however it appears to be different.

invalid

Most helpful comment

I had similar issue - turns out the only problem was I didn't have stylus-loader installed.
npm i stylus stylus-loader style-loader css-loader --save-dev should fix the issue.

All 7 comments

I honestly do not know our current policy for extending components, anyone from @vuetifyjs/dev-team want to chime in?

This seems to be a misconfigured webpack setup, or something. It is possible to import components without issues. Also, make sure to import the es5 version of the component vuetify/es5/components/VDataTable.

edit: The codesandbox error is something entirely different. We need a minimal git repo as a reproduction to continue any troubleshooting

@nekosaur @johnleider alright, I was able to get around the above error using vuetify/es5/components/VDataTable. However now I'm getting this error.

error  in ./node_modules/vuetify/src/stylus/components/_menus.styl
Module build failed: ParseError: expected "indent", got ";"

Here's a minimal repo where I've reproduced the error. Let me know if you have any ideas! It seems to now have to do with stylus errors. https://github.com/kevinjcoleman/vuetify-test

@kevinjcoleman Try removing the .styl rule you have in webpack.base.conf.js. css/stylus rules are already setup using utils.styleLoaders

Closing due to inactivity.

I had similar issue - turns out the only problem was I didn't have stylus-loader installed.
npm i stylus stylus-loader style-loader css-loader --save-dev should fix the issue.

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. Please direct any non-bug questions to our Discord

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Antway picture Antway  路  3Comments

efootstep picture efootstep  路  3Comments

cawa-93 picture cawa-93  路  3Comments

sebastianmacias picture sebastianmacias  路  3Comments

chriswa picture chriswa  路  3Comments