-
Notifications
You must be signed in to change notification settings - Fork 3
Open
Labels
Description
Could we start placing the SQL files directly in the /routes
That way we don't need to navigate a different folder, it's getting a bit confusing finding the SQL files related to the route
Would perhaps be much simpler if we just drop the SQL directly along side the evm.ts file
I'm thinking:
/routes/v1/evm/
/transfers/evm.ts/transfers/evm.sql
We can also just read the SQL directly using readSQL(), we don't need to handle reading all the files by scanning the folders.
const query = await readSQL(path.join(__dirname, "evm.sql"));Another reason for this is we might want to have double SQL files based on params
I'm thinking for ?address param, we might need an entirely different SQL statement for that
Would be organized like:
/transfers/evm.ts/transfers/evm.sql/transfers/evm-address.sql