Kuba
Explore posts from serversKPCKevin Powell - Community
•Created by Arctomachine on 10/26/2024 in #front-end
Responsive nav bar without code duplication
Well, I corrected myself after a bit of thought ;P nice demo. TIL that you can transition grid-template-rows and columns
22 replies
KPCKevin Powell - Community
•Created by Arctomachine on 10/26/2024 in #front-end
Responsive nav bar without code duplication
Now that I'm thinking, what if you actually used grid, used grid areas, and through JS assigned grid-area dynamically to the Links (2), while applying transition for all, or probably better - just height? I haven't tested that, just thinking out loud
22 replies
KPCKevin Powell - Community
•Created by Arctomachine on 10/26/2024 in #front-end
Responsive nav bar without code duplication
In my opinion it's best to maintain two separate components. Initially it seems redundant, but as the site grows it might become beneficial to actually have these two separated - they can really divert in terms of style and even functionality. Of course, YMMV.
As someone suggested, grid could do this task just fine. The problem comes after you want to add transitions for opening, since grid doesn't allow for such tricks.
22 replies
DTDrizzle Team
•Created by 0xsh on 10/3/2024 in #help
How to Drizzle Migrate?
If you ever do - please, let us know - you might help someone who will have similar setup. Good luck!
22 replies
DTDrizzle Team
•Created by dondycles on 10/5/2024 in #help
React Vite env problem
Use
process.env
instead and don't forget to load env vars:
5 replies
DTDrizzle Team
•Created by dondycles on 10/5/2024 in #help
React Vite env problem
But from quickly looking at it -
import.meta.env
is available only when running through vite - which doesn't happen when running drizzle-kit5 replies
DTDrizzle Team
•Created by dondycles on 10/5/2024 in #help
React Vite env problem
Take a look at https://discord.com/channels/1043890932593987624/1290460784912240721
I've gone through the similar debugging process there + given extra tip to consider in such setup
5 replies
DTDrizzle Team
•Created by François on 10/3/2024 in #help
Anyone also experiencing this issue?
That's actually good spot! I was thinking lately about integrating prepared statements myself, but if it results in performance drop, then I might subscribe to these issues for a bit
8 replies
DTDrizzle Team
•Created by 0xsh on 10/3/2024 in #help
How to Drizzle Migrate?
Also, since you're using multi-stage build - you might want to use slimmer base image instead of just
node
22 replies
DTDrizzle Team
•Created by 0xsh on 10/3/2024 in #help
How to Drizzle Migrate?
docker-compose has
depends
or something similar, so you could utilize that22 replies
DTDrizzle Team
•Created by 0xsh on 10/3/2024 in #help
How to Drizzle Migrate?
Or, another idea - you can create a one-shot container, that would contain just drizzle-kit, run the migrations from it
22 replies
DTDrizzle Team
•Created by 0xsh on 10/3/2024 in #help
How to Drizzle Migrate?
Ah, I think I misunderstood. Instead of copying full node_modules, you can install these two packages on the stages you need them, I can't really think about any other solution
22 replies
DTDrizzle Team
•Created by 0xsh on 10/3/2024 in #help
How to Drizzle Migrate?
Move it from dev-dep to normal deps then
22 replies
DTDrizzle Team
•Created by Mozzy on 10/3/2024 in #help
`Error: no such column: unboxes.rarity` with `findMany()`
You're using
query
- did you defined and exported relations for your tables?32 replies
DTDrizzle Team
•Created by 0xsh on 10/3/2024 in #help
How to Drizzle Migrate?
Besides that, MJS is just a regular JS file - and since it is, you can run it without compilation step that ts files require
22 replies
DTDrizzle Team
•Created by 0xsh on 10/3/2024 in #help
How to Drizzle Migrate?
the .mjs is just a convention to tell that a given JS file uses ESM-import syntax, instead of node's
require
22 replies
DTDrizzle Team
•Created by 0xsh on 10/3/2024 in #help
How to Drizzle Migrate?
With mjs, it's just a regular js file that utilizes ESM modules, so you can use
import { ... } from "..."
as usual22 replies
DTDrizzle Team
•Created by 0xsh on 10/3/2024 in #help
How to Drizzle Migrate?
With tsx - you install tsx and just run
tsx migrate.ts
, as simple as that22 replies
DTDrizzle Team
•Created by François on 10/3/2024 in #help
Anyone also experiencing this issue?
I haven't used prepared statements myself, but I would guess that creating a statement and executing it are two different things, and the former might take longer, thus your execution takes circa 40ms
8 replies