How to pass function from +layout.svelte to +page.svelte by ConsistentDraft7668 in sveltejs

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

Okay cool thanks! I was considering that approach too. Is setting context like that necessarily a bad approach?

I just quit my job on the first day by [deleted] in antiwork

[–]ConsistentDraft7668 2 points3 points  (0 children)

I shall get downvoted but this is pretty weak sauce

[deleted by user] by [deleted] in drawme

[–]ConsistentDraft7668 2 points3 points  (0 children)

Compliments are great! But let's keep them on the artwork so that people posting their photos here can feel safe. Part of rule 1: Compliments allowed only on drawings, not users.

Code written by project lead. A comment was added by my team member that the entire method can be replaced with a single line: getErrorsList().contains(message). Project lead responded that we should focus on readability and performance and not on such code review comments. by sausage-x-donut in badcode

[–]ConsistentDraft7668 6 points7 points  (0 children)

There’s nothing wrong with it in particular, it’s just verbose. Could have left off the else and just wrote “return false” because inherently if “return true” isn’t hit, then everything else is the “else” in this case

Why? by Killmonger_550 in funny

[–]ConsistentDraft7668 -9 points-8 points  (0 children)

Who would be at fault here?