Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: a more intuitive way to configure and override #123

Open
wants to merge 16 commits into
base: main
Choose a base branch
from

Conversation

haoqunjiang
Copy link
Member

@haoqunjiang haoqunjiang commented Dec 25, 2024

Backwards compatibility is retained in this PR so there's no breaking changes.

The new defineConfig needs to alter the configs passed in to the following layout:

// [FIRST-EXTENDED-CONFIG]
// ...
// [LAST-EXTENDED-CONFIG]
//
// [BASIC SETUP]
//   pluginVue.configs['flat/base'],
//   '@vue/typescript/setup'
//
// [ALL-OTHER-TYPE-AWARE-RULES-CONFIGURED-BY-USERS]
//
// [ERROR PREVENTION & PERFORMANCE OPTIMIZATION]
//   '@vue/typescript/skip-type-checking-for-js-files'
//   '@vue/typescript/skip-type-checking-for-vue-files-without-ts'
//
// [ONLY REQUIRED WHEN ONE-OR-MORE TYPE-AWARE RULES ARE TURNED-ON]
//   '@vue/typescript/default-project-service-for-ts-files'
//   '@vue/typescript/default-project-service-for-vue-files'
//   '@vue/typescript/type-aware-rules-in-conflit-with-vue'

TODOs:

  • Haven't decided if defineConfigWithVueTs is a good enough name;
  • If defineConfigWithVueTs is omitted, the current error message isn't clear.
  • Shall we append base automatically if the user forgets to add any of vueTsConfigs in the config file?

@haoqunjiang haoqunjiang changed the title [WORK-IN-PROGRESS] feat: a more intuitive config [WORK-IN-PROGRESS] feat: a more intuitive way to configure and override Dec 26, 2024
@haoqunjiang haoqunjiang changed the title [WORK-IN-PROGRESS] feat: a more intuitive way to configure and override feat: a more intuitive way to configure and override Dec 26, 2024
@haoqunjiang haoqunjiang marked this pull request as ready for review December 26, 2024 18:16
@haoqunjiang
Copy link
Member Author

The PR is almost finished, and it works great with the upcoming rewrite of @vue/eslint-config-standard-with-typescript.
But I'm going for a family trip tomorrow… So let's review it until after the New Year.
Happy Holidays to anyone who sees this post!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant