Quasar is not found on "quasar" when using typescript.

  • I am using Vue and adding Quasar as a plugin. Everything works when not using typescript, however, when I add typescript support to Vue, the error says:

    Module '"../node_modules/quasar/dist/types"' has no exported member 'Quasar'.

    Steps to Reproduce

    1. Create a vue project with typescript support:
    vue create sample
    1. Add Quasar plugin:
    vue add quasar@beta
    1. Invoke quasar, answer defaults but add Roboto font and Material icons:
    vue invoke quasar
    1. Now run the project:
    yarn run serve

    Any ideas on how to work around? I’m guessing it has something to do with typescript definitions since it works with just plain javascript. But I’m not sure what to add to the type definitions.

Log in to reply