Skip to main content

usePowerSyncQuery()

function usePowerSyncQuery<T>(
sqlStatement,
parameters,
queryOptions): Result<T>

Type parameters

Type parameterValue
Tany

Parameters

ParameterTypeDefault value
sqlStatementMaybeRef<string>undefined
parametersMaybeRef<any[]>[]
queryOptionsQueryOptionsundefined

Returns

Result<T>

Deprecated

use useQuery instead.

A composable to access a single static query. SQL Statement and query Parameters are watched by default. For a result that updates as the source data changes, use usePowerSyncWatchedQuery instead.