Browse Source
fix: resolve eslint errors as well as TS type errors (#5172 )
* fix: remove TypeScript error suppression for missing types in Vue ESLint config
* fix: enhance application configuration with CSS options type support
pull/5183/head
Journey
1 year ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with
2 additions and
3 deletions
internal/lint-configs/eslint-config/src/configs/vue.ts
internal/vite-config/src/config/application.ts
@ -4,7 +4,6 @@ import { interopDefault } from '../util';
export async function vue ( ) : Promise < Linter.Config [ ] > {
export async function vue ( ) : Promise < Linter.Config [ ] > {
const [ pluginVue , parserVue , parserTs ] = await Promise . all ( [
const [ pluginVue , parserVue , parserTs ] = await Promise . all ( [
// @ts-expect-error missing types
interopDefault ( import ( 'eslint-plugin-vue' ) ) ,
interopDefault ( import ( 'eslint-plugin-vue' ) ) ,
interopDefault ( import ( 'vue-eslint-parser' ) ) ,
interopDefault ( import ( 'vue-eslint-parser' ) ) ,
// @ts-expect-error missing types
// @ts-expect-error missing types
@ -1,4 +1,4 @@
import type { UserConfig } from 'vite' ;
import type { CSSOptions , UserConfig } from 'vite' ;
import type { DefineApplicationOptions } from '../typing' ;
import type { DefineApplicationOptions } from '../typing' ;
@ -100,7 +100,7 @@ function defineApplicationConfig(userConfigPromise?: DefineApplicationOptions) {
} ) ;
} ) ;
}
}
function createCssOptions ( injectGlobalScss = true ) {
function createCssOptions ( injectGlobalScss = true ) : CSSOptions {
const root = findMonorepoRoot ( ) ;
const root = findMonorepoRoot ( ) ;
return {
return {
preprocessorOptions : injectGlobalScss
preprocessorOptions : injectGlobalScss