Closed huang-julien closed 2 years ago
@nuxtjs/color-mode: 3.1.8 nuxt: 3.0.0
Try to autoimport useColorMode in any composable or component
useColorMode
It should be imported
IDE warns that it is not defined. And a page calling useColorMode will throw an error
in @nuxt/kit rc9, it adds autoimport using autoImports:extend which is deprecated
autoImports:extend
Can this be exported by the package ? We would be able to import it manually using import { useColorMode } from "@nuxtjs/color-mode"
import { useColorMode } from "@nuxtjs/color-mode"
@Atinux https://github.com/nuxt-modules/color-mode/pull/161 would resolve this issue
give it a go with v3.2.0 and let me know if it's resolved for you.
solved with 3.2.0 ❤️
Version
@nuxtjs/color-mode: 3.1.8 nuxt: 3.0.0
Reproduction Link
Steps to reproduce
Try to autoimport
useColorMode
in any composable or componentWhat is Expected?
It should be imported
What is actually happening?
IDE warns that it is not defined. And a page calling
useColorMode
will throw an errorWhy
in @nuxt/kit rc9, it adds autoimport using
autoImports:extend
which is deprecatedCan this be exported by the package ? We would be able to import it manually using
import { useColorMode } from "@nuxtjs/color-mode"