Kevin Powell - Community

KPC

Kevin Powell - Community

A friendly place for developers to meet other devs, ask questions, get help, and just have a good time ๐Ÿ™‚.

Join

front-end

resources

back-end

ui-ux

os-and-tools

My Svelte app compiles, but dies on loading. โธ˜Whyโ€ฝ

I'm working on my first Svelte app, & it dies in the browser with: ``js Uncaught Error: No element #globe` found. at instance (App.svelte:5:7) at init (Component.js:135:5)...

How to convert Buff to File Without locally saving it

How do you convert buff to a file? I have an endpoint that modifies images uploaded, and that endpoint returns buffs. Afterwards, I need these buffs to be uploaded in which I will call a service to do that, and the service I'm using requires File to upload the image. How would I do it so that the image is not saved and just passed to the function? ```jsx...

product variants for webshop

Hello! I have been working on a webshop with php and mariadb(mysql). Im working on the product page but im having struggles with product variants. With product variants i mean that one product could have different variants. for example: one hoodie can be in different colors and sizes. One phone can be in different colors, different ram and storage. for the database tables, i have a table for just products that i use for the product list and the idea was to make separate tables for variants that's linked to the an product item....

before unload event - how to change default message "Changes you made may not be saved"?

I created issue - so it would be cool if you know hot to show custom message and answer there https://github.com/vercel/next.js/issues/60696...
No description

Nextjs Framework

Hey guys does the next js work very well In backend (means do you guys recommend it for use cases ?) Or just for the small project...
No description

Error: do not use legacy react-dom/server APIs - react-email question about render

Please let's use 1 place to fix this error So other developers may find this issue on github (it less cases when somebody look for answer exact on this discord server) https://github.com/vercel/next.js/issues/60668...

Django

I started out with Django recently coming from node and I've searched for Django listening architecture and haven't found any, I would just like to know how Django listens to requests and if it's blocking, cause i read somewhere that WSGI deploys workers to interface with the python code but to this threads just wait to return responses even if it's io bound and if we have 4 workers and 4 io operations holding each, does the server reject incoming requests or store them in a queue

socket.io

Good afternoon guys. I'm working on a project that involves using sockets and I've been stuck since last week. The issue I'm facing is that the chat feature I've created allows for real-time communication between the user and admin, but when another user signs in, they can also see the conversation. This is not ideal, as I want the conversation to be private. Can anyone please provide more insight on how to achieve this?

Call API with large amount of data without lagging user

I have that API which can return about 200.000 words at once. I want to let this stored at a nodejs server, so user can fetch some of these words in a way that won't lag him Does anyone know how to do it...

Navigation Bar

Im trying to make my navigation bar appear at the top of everypage and i can scroll and it will still show at the top but idk how to do it im using html and css at the moment and have a js script that im not currently using any help will be appreciated.
No description

Why do people use IIFE to export nodejs modules?

When watching or reading tutorial content about nodejs, I often see people exporting modules like the following ```js module.exports = (function(){ return {...

PHP Header redirection not working on Website, but working on localhost

Hello, i did a login page that after logged in create a session and save the user in the session, then with header('Location: dashboard.php'); It goes to the new page, the admin dashboard. When i try it on my local pc in visual studio with extension serve server, everything is fine. When i upload the files on my cPanel it doesn't work. It creates the session user variable but doesn't execute the header. I can't understand why. Everything in the code works until the header instruction on the serv...
No description

App statistic recording strategies

Hi gang, I'm building an app that does 'stuff'. Things in the app can be on or off. I need to create historical graphs of the totals of 'on' things over time. Simple enough. The app is built with Laravel (PHP/MySQL). My strategy at the moment is to have a daily runner script that selects the count of rows in the tables I'm interested in where status=1 (1 being 'on'). That yields an integer which I dump in a stats table along with the current date. That stats table is then harvested for relevant data the results being passed to the graphing system (Apex) in the main app and a simple datetime graph is produced. All that works. ...

send a notify to specific user

Hello, i am using react native and for the database i use supabase, i used supabase auth template to make users and accounts, every user have an id, i want a function in react that have 2 inputs one for the selected user id the second is for the text I want to send the notification for the selected user input the content will have the text input How can i do that?...

Not getting data of newly added array field

Hey, does anyone know how to add new fields to existing schemas properly? Because I added a new field with is an objectarray and I already saved some data to it which I checked in the mongodbCompass and it worked. But when trying to get the data unsing findOne, I get the document as before but the new field is an empty array and when trying to console.log only the array, it is undefined.... Anyone any idea?...

How do I prevent my div from shrinking so much that it interferes with viewing the contents?

Hello, I'm carrying out a project and I would like to know how I can prevent the width of my div with id #consultory from decreasing so much, because this is disturbing its position in relation to the page and the visualization of the image and the writings inside it; i have tried to define, many different percentages for the width but the problem still happens. Is there any way to limit the width of this div so that it doesn't shrink so much, or is there another way to solve this problem?...

Best course to learn Javascript

I'm looking for a beginners course to Javascript that also might have advanced lessons. Any recommendations? I would prefer a free course on Youtube or something along those lines.

Is it good to continue learning ruby?

For my internship I started learning ruby because they used it for the websites they built. However since i'm done I want to keep learning a backend language/framework for the long-term as I am no longer focused on doing full stack. Is ruby the way to go? Or should I go to something more popular? Because I feel like the lack of popularity of ruby may cause me some problems in finding a job later.

Socket.io

how does it work that sometimes sockets work just fine but sometimes it just stops working at all? Even though everything looks correct?

WordPress Theme compatible with Elementor

Hi! I'm in the process of making a WordPress theme from scratch, one of the requirements is that it has to be compatible with Elementor, I've been looking around but I'm not sure what kind of functions or add-ons I should add to make it fully compatible. Thanks in advance!...