Skip to content

Use Quasar Vite config in Vitest #413

@yusufkandemir

Description

@yusufkandemir

See quasarframework/quasar#17685

In app-vite v3, it would be like:

import { getTestingConfig } from '@quasar/app-vite/testing'

export default defineConfig(async () => ({
  resolve: {
    alias: (await getTestingConfig()).resolve.alias,
  },
}))

This solution can be generalized to apply to stuff other than just resolve.alias, can be put in a wrapper, etc. as needed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions