Skip to content

Plans for supporting appwrite later versions than v17 #405

@maxhoheiser

Description

@maxhoheiser

Description

Are there plans to upgrade this package to extend compatibility to later versions of Appwrite - namely v18 and v20?

Current Situation

The nuxt-appwrite package currently depends on appwrite@^17.0.2, while the latest Appwrite SDK is at v21.0.0. When using nuxt-appwrite alongside a newer version of the Appwrite SDK in the same project, TypeScript type incompatibilities arise.

The Problem

When attempting to use service classes (Databases, Storage, Functions, Teams) from the newer Appwrite SDK with the client instance provided by nuxt-appwrite, TypeScript throws the following error:

Argument of type 'import(".../appwrite@17.0.2/node_modules/appwrite/types/client").Client'
is not assignable to parameter of type 'import(".../appwrite@20.1.0/node_modules/appwrite/types/client").Client'.
Property 'setDevKey' is missing in type from v17 but required in type from v20.

Current Workaround

The only workaround is to use type assertions to bridge the gap:

import { Databases, Storage, Functions, Teams } from 'appwrite'
import type { Client } from 'appwrite'

export const useAppwriteClient = () => {
  const { client, account } = useAppwrite()

  // Type assertion needed due to version mismatch
  const databases = new Databases(client as unknown as Client)
  const storage = new Storage(client as unknown as Client)
  const functions = new Functions(client as unknown as Client)
  const teams = new Teams(client as unknown as Client)

  return { client, account, databases, storage, functions, teams }
}

While this works at runtime (the client interfaces are compatible), it's not ideal from a type safety perspective and requires developers to manually bridge the type gap.

Impact

  • Type Safety: Loss of proper TypeScript type checking
  • Developer Experience: Requires workarounds and manual type assertions
  • Documentation Mismatch: Latest Appwrite documentation references newer SDK features that may not align with v17

Request

Could you please consider upgrading the Appwrite SDK dependency to support v18 and v20? If there are breaking changes preventing this upgrade, would it be possible to:

  1. Update to the latest compatible version (at least v18)
  2. Document any known compatibility issues with newer SDK versions
  3. Provide guidance on the recommended approach for using newer SDK features

Environment

  • nuxt-appwrite: v1.2.0
  • appwrite: v20.1.0 (project dependency)
  • nuxt: v4.1.3
  • typescript: v5.9.3

Thank you for maintaining this package!

Additional information

  • Would you be willing to help implement this feature?
  • Can you think of other implementations of this feature?

Final checks

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions