export const unidriverConfig = { queryByAttribute: (selector: string) => { const queryAttribute = globalThis.__UNIDRIVER_GLOBAL_CONFIG__?.queryAttribute; if (typeof queryAttribute === 'function') { return queryAttribute(selector); } if (queryAttribute?.length !== undefined) { // useful for migration, we dedupe attribute when it's already explicitly passed return selector.startsWith(`[${queryAttribute}=`) ? selector : `[${queryAttribute}="${selector}"]`; } return selector; }, get defaultTimeout() { return globalThis.__UNIDRIVER_GLOBAL_CONFIG__?.defaultTimeout; }, };