Home šŸ‘Øā€šŸ’» IndieHack r/Webdev - Top Weekly Reddit
author

r/Webdev - Top Weekly Reddit

Delve into a community dedicated to the nuances of web development, a space for both front-end and back-end discussions.

September 30, 2024  10:43:25

In so many posts on this subreddit, there's always someone who says they're only coding for the money. And that they wouldn't write a single line of code if they didn't have to.

Although, I get it, coding isnā€™t for everyone. But for me, it's one of the few things that makes me feel confident, competent, and sometimes even like a god. There aren't many things in life where you can think of something and bring it to life so quickly.

I'm 27 now, and I wrote my first code (VB6) when I was 10. And when I was 12 I discovered PHP, learnt how websites work and how they're made. Now that I think about it, I probably learned how websites are made before I learnt how babies are made lol.

And.. it just changed my life. Unlike those who are doing it just for money, I love coding. I code for fun, to pass time, sometimes I even code to forget my pain.

I know some people might not get what Iā€™m trying to tell here. But seriously, give it a shot. Open your IDE, start a new project, and let your thoughts flow freely. Code like an artist. Be as messy or as tidy as you want, create something useful, or something totally pointless. Donā€™t do it for money, do it for yourself. Try to see the beauty in creating something that's uniquely yours. Make your own Frankenstein.

It would be a sad life in my opinion, doing something you don't enjoy to put food on your table. So try coding for yourself, and try to have fun with it. You might end up falling in love with it.

submitted by /u/mekmookbro
[link] [comments]
September 29, 2024  10:43:47
October 4, 2024  12:38:30

I just don't know why it isn't more widely used.

It took me a while to get around to it as my default, rather than using bashed jpgs, but since I did I'm starting to realise it's not that widely used and I'm quite surprised that it isn't more prevalent.

Today I took a large 3000x1500 (1.25MB) jpg file at 300DPI and ran it through a .jpg to .webp converter and the file size is 96kb. It looks no different, no quality loss, 92% size reduction.

So I checked caniuse.com in search of a reason why people don't seem to be using .webp much, and except the demon spawn that is Internet Explorer, it's fully supported.

Do you guys use .webp for images and if not, can you help me to understand why?

Edit: for those who are concerned about export cost or difficulty, you can just drop HD jpgs in bulk into something like this webp conversion tool: https://towebp.io/

submitted by /u/infj-t
[link] [comments]
October 3, 2024  08:05:20

So I charge a certain amount, let's say $200 for creating a section on a website. One person reached out to me and said he wants to add an animation in his website and he would pay me the $200 for it.

When I heard his requirements, I found out I can just do it in 10 minutes as I just have to repeat an animation for 2 minutes in background which will go from top left to bottom right and top right to bottom left for another.

It's so simple that I can finish maybe in less than 5 minutes. Do you think I should charge him the same amount or give him some discount? It's beginning time of working so I'm just confused what to do here as I feel I'm robbing him if I take the full price.

submitted by /u/TheStubbornSurfer
[link] [comments]
October 1, 2024  07:53:42

So I have to preface this, I started working for this small-ish company around a year ago as a front-end developer turning full-stack, building the usual CRUD React applications for relatively major companies in my country. Things started out insanely rough due to my lack of experience and not having a direct colleague to work with in the project but with enough time and patience from my seniors and well as some managerial productivity changes (We didn't even have a proper ticketing system), I've improved a lot and learned some valuable lessons along the way. Everything I'll say are things that I learned and apply directly with my role, so it might be different with other companies

  • Be familiar with building tables, forms and most importantly integrating it with all sorts of API's. This is something that's so insanely important that I can't believe I didn't learn much about it in university. You can build the best looking UI in the world but if it doesn't work well with the API, all hell breaks loose. For beginners, see: PokeAPI and Rick and Morty API.

  • Having no experience is terrifying, you're expected to deliver a final product without knowing the standard of how it should be, and even asked to provided a timeline all the while having no idea if you could even do it. Ask a lot of questions, show your progress to your seniors, never be afraid to come to them with problems, you never know if it's something that they themselves have oversight

  • When given an api for a front end task, test it out first, make sure you're getting all the responses you want. The last thing you want to happen is, you finish building the frontend then realise you're lacking some critical information that will take the backend devs another 2 days to append. Be proactive and try to estimate any issues you could have along the way

  • Figure out who really has the final say in a project, it could be the tech lead, your supervisor, hell maybe even the CEO. This is the guy you want to be in the know if you're making a substantive change to the system. It's very normal for a project to deviate depending on who really leads the team. Even the design can differ significantly and sometimes just be a guideline that ends up outdated by the time the project requirements go through quick, substantive changes.

  • Validations, loadings, error handlings, make sure that your page is open to all situations. Sometimes inconsistencies can happen from the database, whether it's null values, fields that doesn't make sense, your front end should be built to handle all of these situations. It's very easy to fall into the trap of just making a bare minimum page because you're being rushed, but it's always better to take more time to make a robust page rather than churn out several half-assed ones. Hell, make one good page and chances are you can easily recycle some of that code for other pages assuming the functions are similar.

  • Test it, test it, test it, when you've finished developing, make sure to test out the finished build as well, since even that can have some variations from a dev environment. When I say test, I don't just mean for bugs, but for security as well. Don't be the guy that gets exposed in the group chat for having a security oversight so bad, it's hilarious. Hell, use AI to highlight your code and let it point out any potential issues, it's not amazing at building something from scratch, but it's really good at bringing up issues you never thought about. Don't rely too much on it though, it can easily mix up bugs from features if you're not careful with the prompting.

  • Impostor syndrome is normal, hell with how new your are, you are essentially an impostor. Nobody will expect you to know anything deep but like it or not, you'll get better at the things you do regularly. By the time your 2nd, 3rd major project comes around, I guarantee you'll do so many CRUD functions, you'll begin to master it and even get bored of doing the same things everytime. Remember, everyone is just winging it and doing their best until the testers quiet down. If you're finishing your tasks at a timely rate and QA doesn't expose your bugs to the company group chat, or your client doesnt send an angry email to your boss talking about the issue that you single-handedly caused, then you're doing fine.

Oh, and never think that you can hide some bugs under the carpet or pretend you didn't see it because I guarantee you, it will get brought up eventually, and god damn it QA works way too damn hard and you'll feel the

submitted by /u/KikiPolaski
[link] [comments]
October 5, 2024  08:47:41

from legacy code. all warnings in just that single file.

im just so so so flabbergasted lmao.

submitted by /u/tinker_b3lls
[link] [comments]
October 2, 2024  11:39:05

1- Popups.

Everytime you visit a webpage, you will see millions of popups. Join now! button, exclusive discount!! popup, confirm the cookies popup, enter your birth date popup, and more. They never end. I'm tired of this.

2- Info popups

When you hover on some item, it shows a big "info popup" and it blocks the other content. You need to move your cursor out of the "info box" to be able to see the other content. I swear I saw this millions of times, but currently the best example I can give you is on reddit, when you hover on user profile picture on comments section (99.9% of the times its accidental) it will open an annoying popup and won't go away until you move your mouse.

Edit: More examples are the Google translate extension, Goodreads browse page, If I'm not mistaken Netflix website does it too. There are so many of them. Why this is suddenly a trend? You are casually scrolling a website and randomly some stupid 300x200 info box appears and blocking your view. God I hate this one too much I can't stop talking about it.

3- Buttons everywhere

On your viewport, if you make a totally random & accidental click, the chances are you will navigate to another page or it will cause an unwanted action is like 70%. So many clickable stuff is on the screen. I dislike it. I kinda miss the old web.

Will add more when they come to my mind

submitted by /u/Blackwater_7
[link] [comments]
October 5, 2024  17:44:06
Amewz.me - spontaneous 1 on 1 chats with AI matchmaking

Hey all, I made a website similar to Omegle, but it uses AI to match you with people similar to you.

It first asks you a few questions, and then generates a bio about you. Then it uses your bio to match you with similar people into video or text chats. The idea is youā€™ll be able to match with people who have similar interests, hobbies, and personality.

I would love to hear your feedback!

submitted by /u/Critical_Passenger19
[link] [comments]
October 1, 2024  03:04:18

I know I'm just some random person, and this is a popular opinion amongst backend devs, but I'm doing the backend for a decent sized webapp + API stuff. I'm writing my server for efficiency, a monolith to support the limited number of expected users, provide a fast experience with a local DB, and minimize hosting cost.

I really like React functional design, but I'm so tempted to just go back to a mess of HTML templates bundled together by webpack- when I see these frameworks designed for SSR which from my perspective makes no sense for at least my projects. Why should I pay to render non-static pages for potentially bots to access, and why wouldn't I usually want SSG for SEO? And a fetch request for a small JSON object is a lot lighter on network usage than a big render bundle. Not to mention that SSR services seem focused even for small apps on edge, which still has a spin up time, is physically distant from the DB, and are generally more expensive. Not saying there are no applications showing live info that needs to be SEO'd that SSR with caching would be useful, but I feel like that tends to be a bit rare.

I don't agree with trying to blend the server and client, the reality is the concerns of the server and the client are very different and should be treated very differently. Every request to a server is potentially hostile, usually unless something is wrong, a response to a client is safe- so IMO a developer should have a good understanding of the lifecycle of every request to their server, and I feel SSR can hide some of that and lead to potential vulnerabilities(even just in misconfiguration).

So, I choose to not go with one of the many SSR tools, and the other tools I see seem focused on SPAs. Why would I want an SPA?
Why do I need to route /login client and server side just to serve index.html, why not just use URLs for their actual purpose and separate different contexts rather than extensive JS just to view a home page. I do see a huge value about storing a bit of client state in a URL, but imo that's better for separating internal menu tabs for example than whole separate paths(though this is of course subjective). It just is ridiculous for me seeing stuff like someone asking "how to make a multipage app in React?" and being told "make a singlepage app mimicking multipage functionality".

/rant

submitted by /u/Aidan_Welch
[link] [comments]
September 30, 2024  22:31:18

After 49 internships/job applicationsā€¦

After 48 : ā€œ Thank you for your applicationā€¦Unfortunatelyā€¦..ā€

I finally found the job , and got through the interview, all that was left was 1 week until I start Which was supposed to be today.

So yeah my country got into a war this week so the whole thing fell apart

submitted by /u/Technical-Article221
[link] [comments]
September 29, 2024  22:08:19

I'm not old, but I come from a time when personal websites still used to be a thing: it was admittedly a time when CSS flexboxes didn't exist, but despite that we managed. Somehow.

Anyway, it was common for geeks and such to fiddle around with HTML and PHPā€”but with one big taboo: don't ever try to create a login system. This is because you could create something simple, but how secure is it going to be? You cannot store passwords in plain text, obviously; also, you gotta make sure you keep the user logged in; and what about SQL injection? did you think about SQL injection?

Fast forward to 2024, and I'm getting back into the hobby of web development. I'm still an amateur, and by no means a professional. However, the landscape has since then changed: we have flexboxes (thank god for that)ā€”but we also have way better security measures nowadays. One example: prepared statements in SQL. And what about local storage/session storage? I don't remember hearing about any of this back in the day.

And so, I am left wondering: is a login system still impossible to do as an amateur? Or have the times really changed? Do HTML5, PHP 8 and the like make this problem easy to solve even for beginners, almost like... flexboxes made everything trivial when it comes to centering stuff?

submitted by /u/Mirieste
[link] [comments]
October 3, 2024  03:18:11

The number one frustration I have with developing in WordPress is the near non-existence of a professional community of developers. If I search for any problem I'm having with Laravel, the resources available are mostly catered to professional developers. If I'm having problems developing a WordPress plugin/theme the resources I find with good are mostly directed towards:

  • Amateur developers who know how to code some PHP, but their WordPress code still relies on a large number of third party plugins that I am not interested in using.
  • But it's mostly all for end users that don't know how to write a single line of PHP code.

It's largely an SEO problem. Even if I specify "developer", "advanced", "intermediate", etc, in my search it's not enough. The majority of search results are completely useless to me. There's far too many people who think of themselves as a "WordPress Guru", but don't know what a unit test is.

WordPress itself is a fine platform, it's got some idiosyncrasies from it's origins in the very early days of PHP, but it's mostly fine.

Sorry for my rant.

submitted by /u/Artsy_ultra_violence
[link] [comments]
October 1, 2024  00:18:35

After working as a full stack web dev for the past 4 years I was laid off 10 months ago and it's not looking like I'll land anything anytime soon.

Applied to bunch of customer service jobs yesterday and gonna take one soon. I'm keeping my hopes high and just controlling what I can, and really focusing on my health since it's the most important thing. I'm glad to have an opportunity to work doing anything at this point so I feel grateful there are still jobs out there even if they aren't the ones I want.

Just wanted to check in and see how everyone is doing and say you're not the only one. Your job is not your identity. Just do what you can.

submitted by /u/InTheCamusd
[link] [comments]
September 30, 2024  01:25:40

The user is not even authenticated! What resource exactly are we protecting with CSRF token if there Is no authenticated user?!!!

submitted by /u/raulalexo99
[link] [comments]
October 3, 2024  17:50:22

I'm in deer need of help !

I coded an application that calculate a load of distance with google API Matrix.

On google api Console, it says i only have 5155 requests, why did it cost 1700 euros ?

Does anyone has s way to contact google or some support ?

submitted by /u/NaightFr
[link] [comments]
October 3, 2024  14:17:20

Or, maybe on the opposite end, you see something and you go "ewwww, worst nightmare"

submitted by /u/qyrusai
[link] [comments]
October 1, 2024  21:51:59
  1. Their ratings are fake

  2. They side with scammy vendors vs. real customers

  3. They have some deep security problems

I recently purchased a product on Envato and had some issues with it, which led me to give it a low rating. Not a problem. It happens.

Then, one day, without warning, the rating disappears. Very confusing. So I'm pretty upset so I rate it again very lowly.

The rating gets deleted again and they accuse me of asking for a higher rating in exchange for a higher rating (which I didn't do). I did some digging and they have a ticket filing platform. Somehow the vendor was able to create an account on my behalf (using my email) and create a fake interaction where I asked for a higher rating.

I'm now blocked from rating the item again otherwise my account gets banned lol

DO NOT TRUST.

submitted by /u/helloworldlalaland
[link] [comments]
October 3, 2024  06:32:47

Despite nearly seven years of experience and building two fairly successful startups, I struggle with live codingā€”even on the simplest tasks. Iā€™ve never had to perform under such scrutiny before, and itā€™s quite frustrating. I donā€™t mind tackling the task on my own, but not during an interview :(

submitted by /u/Subject_You_4636
[link] [comments]
October 4, 2024  09:14:17

I just finished the first website that I was officially tasked with, it is a little website that works as an advert for the company I work for, it was slightly challenging since it had many absolute elements and animations, but I managed.

After I finished it and all was good, I discovered that it doesn't work on some older Chrome versions (like 2017/18 Chrome) so I google around, learned about the difference in CSS support between browsers and changed some styles, it looked much better.

Later on, one of our design guys tells me it doesn't look good on IPhone, now I never thought about Safari support, I don't have an IPhone or a Mac, so this just gotten a lot more complicated.

Add to that, I tried it on Edge (I have the Pre-chromium version) and a good deal of stuff were broken.

I am not given a specific number of versions for the browsers I am supposed to support, and I don't know the 'professional' way to approach this, how far am I supposed to support? What about libraries that I am using that I can't control? (SwiperJS as an example).

Making sure I manage to implement the design I am tasked with was bad enough, but this is a completely new can of worms :/

Any tips?

submitted by /u/CyperFlicker
[link] [comments]
October 4, 2024  16:47:42

I am currently working with a company as a Full stack Web developer, I've been here for around 5 years now, I recently applied to a job offer and I got the first interview.

I don't understand the logic for asking how much I am earning and how much is my expected salary. I mean, why do they care? Shouldn't they just care about how much the interviewer wants to earn? Why do they need to know your current salary?

How can the "current salary" information affect the whole job process interview?

Let's say you have 3 FINAL candidates, roughly speaking, they are all the same (technical, soft skills, etc..) the only difference is their current salary and these 3 candidates, for some reason want to earn the same amount, so for example:

Current salary

DevA :$ 5000.00 USD DevB: $ 3000.00 USD DevC: $ 2000.00 USD 

Expected Salary:

DevA: $ 7000.00 USD DevB: $ 7000.00 USD DevC: $ 7000.00 USD 

Let's say Company 'X' can only recruit one engineer, what would be their decision? How can their decision be influenced by the current & expected salary? Would they reject the 3 engineers and look for someone else?

Why DevC wouldn't be a good choice? because he/she earns less than the rest? Keep in mind all 3 candidates have the same experience, they are not juniors (in this hypothetical scenario).

They should only ask for your expected salary, nothing else!

submitted by /u/andres2142
[link] [comments]
October 5, 2024  15:09:58

I got into web development for two main reasons:

  1. I wanted to build my own ideas without relying on someone else.

  2. I was tired of encountering bugs and bad UX in almost every app or website I use, and I wanted to do better.

After working as a Full Stack Developer for a few years now, there's one thing I still donā€™t understand. Why do large apps, like Instagram or Reddit, still have simple bugs and bad UX that seem easy to fix? These companies have massive resources and access to top developers, right? So what are the devs doing all day? It just doesn't make sense to me.

Would love to hear some insights or perspectives on this from others in the industry.

submitted by /u/xelamoth
[link] [comments]