Skip to content

Commit

Permalink
feat(module): provide types for config overrides
Browse files Browse the repository at this point in the history
  • Loading branch information
antfu committed Apr 15, 2024
1 parent 6509ce6 commit 55b3806
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion packages/module/src/modules/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,10 @@ async function generateESLintConfig(options: ModuleOptions, nuxt: Nuxt, addons:
`)`,
'',
'export function withNuxt(...customs) {',
' return configs.clone().append(...customs).onResolved(configs => typegen(configs, { dtsPath: new URL("./eslint-typegen.d.ts", import.meta.url) }))',
' return configs',
' .clone()',
' .append(...customs)',
' .onResolved(configs => typegen(configs, { dtsPath: new URL("./eslint-typegen.d.ts", import.meta.url), augmentFlatConfigUtils: true }))',
'}',
'',
'export default withNuxt',
Expand Down

0 comments on commit 55b3806

Please sign in to comment.