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: expose @vitejs/plugin-vue config #215

Merged
merged 3 commits into from
Feb 9, 2021

Conversation

ChrisShank
Copy link
Contributor

Fixes #214

@ChrisShank ChrisShank changed the title feat(template-compiler-options): expose config to add custom elements feat: expose config to add custom elements Jan 26, 2021
@antfu
Copy link
Member

antfu commented Jan 26, 2021

I personally don't feel it's good to be a root-level config option as it loses some context here. Maybe we can have a config entry that forwards the options for @vitejs/plugin-vue instead?

@ChrisShank
Copy link
Contributor Author

ChrisShank commented Jan 26, 2021

@antfu Are there any other options from @vitejs/plugin-vue that you think would be beneficial to expose?

MaybetemplateCompiler.isCustomElement or template.compilerOptions.isCustomElement would be better?

@antfu
Copy link
Member

antfu commented Jan 27, 2021

I am thinking to have a top-level option vueOptions, where

 const vuePlugin = createVuePlugin({
    include: [/\.vue$/, /\.md$/],
    ...configs.vueOptions
  })

WDYT?

@ChrisShank
Copy link
Contributor Author

ChrisShank commented Jan 27, 2021

Thanks for clarifying, makes sense to me. Ill update the PR later today!! 😃

@ChrisShank ChrisShank changed the title feat: expose config to add custom elements feat: expose @vitejs/plugin-vue config Jan 28, 2021
@ChrisShank
Copy link
Contributor Author

@kiaking @antfu Any other feedback for this?

src/node/config.ts Outdated Show resolved Hide resolved
src/node/config.ts Outdated Show resolved Hide resolved
@kiaking kiaking merged commit 5b34c6a into vuejs:master Feb 9, 2021
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jan 21, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Expose configuration for @vitejs/plugin-vue
3 participants