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

refactor: split runtime types #213

Merged
merged 1 commit into from
Jan 14, 2022
Merged

refactor: split runtime types #213

merged 1 commit into from
Jan 14, 2022

Conversation

pi0
Copy link
Contributor

@pi0 pi0 commented Jan 14, 2022

Types of changes

  • Bug fix (a non-breaking change which fixes an issue)
  • New feature (a non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Description

Refactor runtime types so they are bundled with mkdist. resolves #211.

Checklist:

  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my changes (if not applicable, please state why)

@pi0 pi0 marked this pull request as draft January 14, 2022 13:50
@pi0 pi0 force-pushed the refactor/runtime-types branch from e046cc1 to 6cbf56b Compare January 14, 2022 13:55
@pi0 pi0 marked this pull request as ready for review January 14, 2022 13:55
@pi0 pi0 mentioned this pull request Jan 14, 2022
@@ -19,7 +51,7 @@ export default defineNuxtModule<StrapiOptions>({
version: 'v4',
cookie: {}
},
setup (options: StrapiOptions, nuxt: Nuxt) {
setup (options: ModuleOptions, nuxt: Nuxt) {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tip: You don't need types here. They are already inferred by defineNuxtModule

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Didn't know that, should we remove it then?

@benjamincanac benjamincanac merged commit 6fab1ce into dev Jan 14, 2022
@benjamincanac benjamincanac deleted the refactor/runtime-types branch January 14, 2022 18:33
@benjamincanac
Copy link
Member

Thanks a lot @pi0 🙂

* @type string
* @example 'v3'
*/
version?: 'v4' | 'v4'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @pi0

Shouldn't this be 'v4' | 'v3'?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@luke-z Thanks for the heads up I missed this, fixed in 6ad2e38.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome :)

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.

Fix types resolution in IDE
3 participants