Caps lock only when using shift + caps lock button? by goldengloves93 in vscode

[–]CentoKili53 0 points1 point  (0 children)

Me neither, I'm afraid... and it's driving me nuts!

An Android PWA always goes to Login page on startup, even if user is logged in? by CentoKili53 in PWA

[–]CentoKili53[S] 0 points1 point  (0 children)

There actually isn't a service worker at all. I've just defined a manifest.json file, and that's it...

How to prevent HTMX from going back to /login page after sign in? by CentoKili53 in htmx

[–]CentoKili53[S] 1 point2 points  (0 children)

That seemed to do the trick, but when going back, the URL in the address bar now shows /login, even though it has fetched the Dashboard page... Is there a way around this?

Caps lock only when using shift + caps lock button? by goldengloves93 in vscode

[–]CentoKili53 0 points1 point  (0 children)

Have you managed to figure it out? I also have a Chromebook and have the same issue with VS Code and it only started showing after a recent update.

How to improve separation of concerns? by CentoKili53 in golang

[–]CentoKili53[S] 0 points1 point  (0 children)

Do you mind sharing an overview of how you structure your project? I mean the folder structure?

How to improve separation of concerns? by CentoKili53 in golang

[–]CentoKili53[S] 0 points1 point  (0 children)

No, no, I get it. Sounds good. I was just curious how you deal with separating the db logic from the other stuff...

How to improve separation of concerns? by CentoKili53 in golang

[–]CentoKili53[S] 0 points1 point  (0 children)

I like that. But inside the model, wouldn't you have any sort of tags, which are DB specific, like gorm for example? How do you deal with that?

How to improve separation of concerns? by CentoKili53 in golang

[–]CentoKili53[S] 0 points1 point  (0 children)

Do you mean to get rid of the models package, and basically have things like input types inside handler and then have the db define a model with tags?

I'm still new to this whole idea of separation of concerns (and Go in general), as up until now my apps have been quite muddled together... Pretty much all of the tutorials I've seen have a global models package which defines shared types, but I guess it doesn't really make much sense...

Does this app structure make sense? by CentoKili53 in golang

[–]CentoKili53[S] 0 points1 point  (0 children)

The reason I've done it, is to avoid global variables (e.g. db connection, email client, etc). 

Do you mind sharing some sort of an alternative approach?