Skip to content

v2.0.0

Choose a tag to compare

@github-actions github-actions released this 18 Apr 06:10
· 184 commits to main since this release

   🚨 Breaking Changes

   ℹ️ Migration

Tip

Breaking changes are limited to using typed OpenAPI clients. If you don't require typed clients in your Nuxt application, you can skip this migration section.

With Nuxt API Party v2, the OpenAPI support has been refactored to conform to the upcoming version of the openapi-types package (v7). This change introduces a few breaking changes to the API Party OpenAPI client:

  • Dropped support for OpenAPI 2.0 (Swagger).
  • Previously, you could omit the leading slash in the API path. This is no longer possible. You must now include the leading slash in the path, just like in the OpenAPI specification.
  • The pathParams fetch option has been renamed to path to better align with the OpenAPI specification and allow for more flexibility in the future.
const { data } = await usePetStoreData(
-  'user/{username}',
+  '/user/{username}', 
  {
-    pathParams: { username: 'user1' }, 
+    path: { username: 'user1' }, 
  }
)
    View changes on GitHub