upleveled / eslint-config-upleveled

UpLeveled ESLint defaults for programming in JavaScript, TypeScript, React, Next.js, Node.js, Postgres.js
https://www.npmjs.com/package/eslint-config-upleveled
39 stars 12 forks source link

Allow async database query functions without cache() wrapper #396

Closed karlhorky closed 2 months ago

karlhorky commented 2 months ago

For syntax like in Expo API Routes:

export const getAnimals2Insecure = async () => {
  const animals = await sql<Animal[]>`
    SELECT
      *
    FROM
      animals
  `;
  return animals;
};
codesandbox-ci[bot] commented 2 months ago

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

karlhorky commented 2 months ago

@ProchaLu Thanks for the review! Released in eslint-config-upleveled@8.4.0