Quasar: "export 'Quasar' was not found in 'quasar'

Created on 16 Sep 2019  路  12Comments  路  Source: quasarframework/quasar

OS: win7
Node: 10.16.3
NPM: 6.9.0
Browsers: firefox, chrome, opera

The error occurs immediately after a new installation.

image

bug

All 12 comments

@Steiger04 please provide more info ie. quasar info log (if using quasar cli), what mode you are on (UMD/Vue Plugin/ etc..), steps you did to get this error, etc... thx.

Try to remove node_modules folder and yarn.lock or package-lock.json.
Then do a yarn in the project folder and then quasar dev - it should work.
Windows is known to have more problems with npm.

@metalsadman @pdanpdan
The error message with yarn is identical, so no difference. I did the following:
1) npm install -g @ quasar / cli
2) quasar create mslfe-ibr-quasar
3) cd mslfe-ibr-quasar
4) quasar dev
And that was about it.

quasar info outputs:

image

@metalsadman @pdanpdan
The error message with yarn is identical, so no difference. I did the following:

  1. npm install -g @ quasar / cli
  2. quasar create mslfe-ibr-quasar
  3. cd mslfe-ibr-quasar
  4. quasar dev
    And that was about it.

quasar info outputs:

image

did the steps you did, and ran without the error.

@Steiger04 Can you post the answers that you're giving to the Project creation prompts?

@rstoenescu Here are my answers:

carsten@PC-Buero /cygdrive/e/node_workspace/iobroker/node_modules/iobroker.milight-smart-light
$ quasar create mslfe-ibr-quasar

? Project name (internal usage for dev) mslfe-ibr-quasar
? Project product name (must start with letter if building mobile apps) Quasar App
? Project description A Quasar Framework app
? Author Steiger04 mygithub@t-online.de
? Pick your favorite CSS preprocessor: (can be changed later) SCSS
? Pick a Quasar components & directives import strategy: (can be changed later) Auto import
? Check the features needed for your project: ESLint, Vuex, Axios
? Pick an ESLint preset: Standard
? Cordova id (disregard if not building mobile apps) org.cordova.quasar.app
? Should we run npm install for you after the project has been created? (recommended) yarn

Quasar CLI 路 Generated "mslfe-ibr-quasar".

[*] Installing project dependencies ...

yarn install v1.17.3
info No lockfile found.
[1/5] Validating package.json...
[2/5] Resolving packages...
[3/5] Fetching packages...
info [email protected]: The platform "win32" is incompatible with this module.
info "[email protected]" is an optional dependency and failed compatibility check. Excluding it from installation.
info [email protected]: The platform "win32" is incompatible with this module.
info "[email protected]" is an optional dependency and failed compatibility check. Excluding it from installation.
[4/5] Linking dependencies...
warning " > [email protected]" has unmet peer dependency "webpack@>=2.0.0 <5.0.0".
[5/5] Building fresh packages...
success Saved lockfile.
Done in 57.95s.

[*] Running eslint --fix to comply with chosen preset rules...

yarn run v1.17.3
$ eslint --ext .js,.vue src --fix
Done in 6.10s.

[*] Quasar Project initialization finished!

To get started:

cd mslfe-ibr-quasar
quasar dev

Documentation can be found at: https://quasar.dev

Quasar is relying on donations to evolve. We'd be very grateful if you can
read our manifest on "Why donations are important": https://quasar.dev/why-donate
Donation campaign: https://donate.quasar.dev
Any amount is very welcomed.
If invoices are required, please first contact [email protected]

Please give us a star on Github if you appreciate our work:
https://github.com/quasarframework/quasar

Enjoy! - Quasar Team

馃ぃ /cygdrive/e/node_workspace/iobroker/node_modules

You are creating a new project inside a node_modules folder. Don't :)
Create it outside of any such folders.

I think you should import it as

import Quasar from 'quasar';

not

import { Quasar } from 'quasar';

I think you should import it as

import Quasar from 'quasar';

not

import { Quasar } from 'quasar';

work for me

I think you may not have Babel.

The way you import it depends on whether you've set to "import everything (all)" or "auto import (treeshake Quasar).

For import everything: import Quasar from 'quasar'
For auto import: import { Quasar } from 'quasar'

Was this page helpful?
0 / 5 - 0 ratings

Related issues

jippy89 picture jippy89  路  3Comments

florensiuslaylim picture florensiuslaylim  路  3Comments

xereda picture xereda  路  3Comments

adwidianjaya picture adwidianjaya  路  3Comments

Bangood picture Bangood  路  3Comments