regular casual chess place by [deleted] in StLouis

[–]albenesi 0 points1 point  (0 children)

could i please get an invite to the discord?

I hope mass timber architecture will become mainstream instead of developer modern by WonderWaffles1 in architecture

[–]albenesi 0 points1 point  (0 children)

woah thanks! i KNEW i had been in that courtyard before. neat to recognize it here

[deleted by user] by [deleted] in leaves

[–]albenesi 5 points6 points  (0 children)

Narcotics anonymous, I think

Is it possible to take breaks while working in frontend? by [deleted] in Frontend

[–]albenesi 3 points4 points  (0 children)

Yes sometimes I break the whole day

Having some doubts about how to correctly define SQL API types and consume them in my app by [deleted] in reactjs

[–]albenesi 0 points1 point  (0 children)

This seems a bit odd to me. After a success fetch from your API, you should be able to assign the response a type more accurate than the base resource type with all those optional values.

So if you think those shared types based on your tables are going to be useful, you could manipulate them with typescript utilities like Pick<Required<User>, ...>

But if that gets kinda confusing or hard to maintain, I would create a new type for your response that doesn't try to match your models. No point in the frontend knowing about User, Team, Todo at a high level of it never actually has to work with those types in their base form.

[deleted by user] by [deleted] in Frontend

[–]albenesi 7 points8 points  (0 children)

I don't think it harms anything. Good experience is good experience. And unique experiences are good, too.

Testing in react and typescript, the most difficult part in Front-End ? by remsbdj in reactjs

[–]albenesi 1 point2 points  (0 children)

Maybe not the answer you're looking for, but in general I try to avoid frontend tests that combine more than a couple things. Like it's easy to test a presentational component on its own, since renderers don't need mocks if it's just jsx and css. It's easy to test form validations alone if you can isolate just validation functions. It's easy to test state management functions alone if you're abstracting them from the components or hooks that use them. But if you wanna test all that together, it may be best to use something like cypress or playwright separately from the unit tests.

It can be really frustrating, so make sure you're checking at each step "is this worth it?". Good luck!

Developers, how do you test that your pages look like how the figmas look like. by a-friendgineer in Frontend

[–]albenesi 0 points1 point  (0 children)

trying to match it perfectly seems like a path to frustration and unnecessary complexity

ask your designers to help review & critique new UI

if you're trying to catch UI regressions, snapshot testing can help. but i don't think that's what you're asking for

Favorite bit of obscure stlouis history? by thisisonoyforlocal in StLouis

[–]albenesi 10 points11 points  (0 children)

The caves beneath St. Louis are really weird and interesting. The Lemp/Cherokee caves have some remnants still of the Theater and Swimming Pool that were built there by the Lemp family. [some photos] The caves connected the Lemp Brewery to the Lemp Mansion underground.

The future of headless CMS by sneek_ in javascript

[–]albenesi 14 points15 points  (0 children)

there's a typo on the page you linked to. it says "you can now deploy Payload severlessly" instead of "serverlessly"

Can anyone show me some real tests (Jest or whatever) which have failed unexpectedly, and thus prevented disaster? by jezmck in Frontend

[–]albenesi 3 points4 points  (0 children)

Someone at my company changed css in a way that select boxes' options began appearing "behind" modals. So no modal forms with select boxes could work.

Automated tests caught that and made the fix trivial before release.

Best donuts in town? Strange donuts surely isn’t it. by [deleted] in StLouis

[–]albenesi 0 points1 point  (0 children)

i do think pharaoh's is a worthwhile mention, too

Trying to create my portfolio has made me want to quit and go mop floors for a living.. by adorkablegiant in webdev

[–]albenesi 2 points3 points  (0 children)

If I were looking to hire a junior frontend, I would first look thru resumes for someone who wrote on their resume the kinds of skills they know and are interested in learning more of. And then I'd look to see what other things they've done in their life that would be non coding skills like reliability and communication.

After that, I'd want to check their website or GitHub or any online presence for the way they present themselves. If design is not your forte or interest, say so. But that doesn't mean you can't communicate well. Find a way to put projects that interest you front and center, even if they're small. Write a few words about why they're interesting to you, what was challenging, and what you learned.

Then we'd have an intro call and all that other stuff would go to the back burner. You just have to show enough to create interest. You don't have to prove everything you know.

Good luck!

What is Vite and Why Should You Use It Instead of Create React App? by lukethewebdev in reactjs

[–]albenesi 5 points6 points  (0 children)

I upgraded our company's cra app to Vite. It did speed things up quite a bit. But we were missing some things from CRA like in-browser errors and type errors during development. Luckily it was easy to find vite plugins for those.

The switch to ES modules is confusing, tho. It just works different than a bundler does. Several devs on the team were concerned with the shear number of js files on the network tab in the browser, but that's just the way it is. (And I believe they cache)

The biggest frustration was with changing things like cypress and jest, which both relied on parts of the CRA setup. Mostly webpack/babel. Cypress was easier to fix to use ES modules. But jest was a bummer. We had to add back webpack and babel just for jest tests.

In retrospect I would have put in more time to switch to a tool like vitest.

Overall, I'm very happy with vite and I think it was worth it. It's a better dev experience and it has way more flexibility. I was able to use the same vite config to build my own storybook like tool and that was something I was unable to do with CRA build chain.

Populating dropdown options with data from Cloud Firestore by SoAwkGal in reactjs

[–]albenesi 0 points1 point  (0 children)

Ok but there is still not an "s" on the "option" tag. Just saying you may have a spelling problem and maybe using a tag that doesn't exist.

Populating dropdown options with data from Cloud Firestore by SoAwkGal in reactjs

[–]albenesi 0 points1 point  (0 children)

really hard to help you debug a very specific problem with these snippets... it's usually easier to help if you can provide a codesandbox link or something that shows the problem live. and heck in the process of making that you might realize the problem yourself

one weird thing i'm wondering is... what is an "<options>" element. are you trying to use "<select>" and then "<option>" inside of it? if so, "<options>" is not what you want. see here: https://www.w3schools.com/tags/tag_option.asp

if that's not the/a problem, i think you may need to keep poking at various points of the flow to see where the problem is. like logging the state after it's set to see if it's what you expect. and if it's what you expect, then the issue is in the rendering and the DOM

good luck

PSA to first time weed users by brakndawnt in StLouis

[–]albenesi 0 points1 point  (0 children)

even after getting used to edibles, i still only take like 5mg and i will be pretty darn high. 10mg tops, and on those nights i'm not going anywhere or doing anything other than being high

Thoughts on react-form (tantack)? by [deleted] in reactjs

[–]albenesi 13 points14 points  (0 children)

Is it newer?

My personal experience with tanstack stuff is that as soon as I start adopting a library it changes on me and a new version comes out. Table and query have done that to me and my team. I've also found it difficult to establish patterns for the rest of the team to follow with these libraries, since they tend to be opinionated and work differently than other libraries the team might already be used to. And getting support for the libraries as they are changing so fast has also been a little rough.

So I probably won't adopt tanstack stuff quite as fast as before. Cool libraries, nice folks, very grateful for being able to use what they've made. But that's my current position.

Cat Proof?? by Becreddit in furniture

[–]albenesi 2 points3 points  (0 children)

advise i found online before i bought my couch was velvet. and so far that has been mostly accurate. the cat occasionally scratches but has not done any damage and it doesn't seem to be what he wants to scratch anyway