/wdg/ - Web Development General

Previous Thread: >Free resources to get started
Get a good understanding of HTML, CSS and JavaScript.
MDN web docs offer a good introduction (independent of your browser choice)
developer.mozilla.org/en-US/docs/Learn
freecodecamp.com/
codecademy.com/

>Further resources
developer.mozilla.org/en-US/docs/Web - General documentation for HTML, CSS & JavaScript
github.com/kamranahmedse/developer-roadmap - Roadmap
stackoverflow.com/ - Developers asking questions and helping each other

>Tools
jsfiddle.net/ - Use this and post a link, if you need help with your code
caniuse.com/ - Check browser support for front-end web technologies

Attached: 1567848913018.jpg (824x553, 168K)

Other urls found in this thread:

animejs.com/
github.com/aspnet/AspNetCore/issues/12189
pastebin.com/gfBPg24A
learn.freecodecamp.org/responsive-web-design/responsive-web-design-projects
freshworks.com/live-chat-software/features/
twitter.com/NSFWRedditVideo

>anime
ew

it's a pretty cool framework

animejs.com/

How does it work with react?

I almost asked the question why my own library doesn't properly work for the inverse use case.

Yeah, it's because I made it.

Would I not have to write a new template rule each time that I add another row? Seems rather complicated. Also grid is ... difficult as I am targeting older mobiles, too.

You could rather tell me what the fuck is wrong with my code.

Exactly like every other library: "as nicely as you let it."

Is it true .NET Core 3.0 and Blazor SSR will destroy any other stacks? I am not a Windows guy but if it's really better, why not?

My answer was a bit over top, granted. But it is true nevertheless

Actually, if you have to ask which os to use, in that specific case, ubuntu is the better choice of the two for you.

Yes

Razor Components are still slower!

>.NET Core
>Windows
retard

I wanted to say a Microsoft guy. ;)

Slower than what?

What is going on?

foreach ($names AS $name) {
$id = $name['id'];
echo $id;
$customized_name_list[$id]['address'] = $name['address'];
}


It's echoing all the ids but only inserting the last one into customized name list. How is it not adding the other ids into the array?

Until they can figure out a compelling way to generate small enough binaries that it is actually worth using, it will remain bloatware at best. It gets shilled around here a ton for whatever reason, but it is nowhere near production ready and Microsoft have not said anything to hint that they will solve this issue in the near future. In fact, the most recent change increased the size as opposed to decrease.

For example, this issue from 2 months ago:
github.com/aspnet/AspNetCore/issues/12189
"We are working on it, kthnxbai."

apparently math random is not the way to go when you have a json with 32000 lines

nvm, I was redeclaring the array inside the foreach lmao.

senior dev, everyone.

I was about to write that you're probably overwriting something but thought that you're gonna figure it out soon enough.

Mental retard here.
So I'm using Stylus to change website appearance, and I want to know how to add the CRT line effect on top of the following:
body {
background-color: #0f0900;
background-image: radial-gradient(
rgba(255,170,0,0.25), #0f0900 120%);
background-size: 100% 100%;
background-repeat: no-repeat;
background-position: center top;
background-attachment: fixed;
}

put your custom crap in a before or after pseudo selector and overlay body with pointer-events: none; to let clicks thru

Anyone use Django? I'm so lost as to what the purpose of a Manager is. But I believe the manager is what's fucking up my custom user model

>make the effort to learn react fast as fuck to get a job because apparently every listing wants react
>learning it fast as fuck
>start thinking im making mistakes and start getting lost on practice questions and feel like an absolute brainlet
>mfw my dumb solution that looks like nonsense was close to the actual solution the instructor planned on showing anyway
>mfw i was basically doing the right thing from the beginning

Attached: ebinshine.gif (296x262, 131K)

you're a senior dev and this is how you indent,jesus

Does anyone have any good leads on how to get back into PHP? I havent touched it in a year and really need to get back into for jobs and stuff. Any tutorials would be a big help.

forgot to put the links in the OP

>pastebin.com/gfBPg24A - Collection of PHP links.

Managers provide database operations to models, in essence they're the glue between models and the db layer. They actually exist even if you don't instantiate them and provide the basic query sets you're used to.

Is PHP even worth touching? Seems like a dying language

Thanks!

Where I live (in SoCal) a lot of companies use it. I would say it would be a third if not half of the available jobs here which is why I am getting back into it as stated here not sure how it is outside of this state though

Depends on your location really

can't believe i'm struggling with this, i have a button that loads the next n items in a list, how do i hide my button when i'm nearing the end of the array? don't know the length of the array in advance

are you in control of the back-end? what json are you getting? do you have a "total" key inside of the json? is it handled with nextPageTokens? do the next page tokens stop?

Any way I can get the 3rd element of this MAP, without iterating through it, knowing its key, or converting the whole thing into an array?

Attached: 1568932021.png (652x176, 16K)

No this is pretty basic stuff, 30000 lines of json with as far as i can tell with normal +1 id increments. So technically I could get the total from -1 but I don't know how to proceed from there.
My page loads 100 items at a time.

If you want to do something like that it'd be best to just make a new Map class where you store the keys in an extra array to easily index into.
Otherwise, just
function takeNth(iterable, n) {
for (const value of iterable) {
if (n-- === 0) {
return value;
}
}
}
// ...
map.get(takeNth(map.keys(), 2))
but this is pretty ugly, should

dude, post part of your code and the tech you are using, do you have the json in one file? static site? what are you building?

I vote for including theodinproject.com in the OP.
>b-but Ruby
They have a JS track now, just recently the included the Node course.

PHP and Ruby are the two best languages for remote/freelance jobs

>linking to w3schools to begin with
>saying w3schools has any relations to w3c
>saying w3schools IS part of w3c
Into the trash this garbage goes.

Disgusting

Attached: unknown.png (413x68, 5K)

Lmao, didn't even notice that.

Thanks, I'll try it later

>console.log(foo[0]) gives a result
>console.log(foo[0].bar) gives foo[0] is undefined
i'm too stupid for this shit

>AS
this triggers me

Is this what you were trying to do?
If this didn't help explain further what you don't understand.

Attached: anon.png (467x268, 11K)

I get this behavior only when I try to make it responsive, on desktop it works perfectly

Why is this not aligned?

Attached: thisdoesntmakesense.png (685x685, 94K)

I think you'll understand now.

Attached: anon2.png (673x238, 12K)

That helps but I think it's react being a bitch. Passing a prop to a component through router and I don't know.
This just doesn't make any sense to me

Attached: anon3.png (486x258, 8K)

I may be wrong because I don't know react that well, but think about this.
A react component is basically an object. Props are like a special type that has specific behavior inside this react component.
Are you trying to put a react component or prop inside an array and then trying to access it? That's not gonna work.

No it's simply some data that I passed as a prop to a functional component and as I said, I can log the prop in console just fine but as soon as I try to go any deeper than that, react shits itself.

With timeout I can get properties out but it instantly gives me undefined after that and crashes, in console it's even crazier. The object is my regular console.log which goes through just fine.
>Object FrontPage.tsx:18
>Uncaught TypeError: Cannot read property 'releasedate' of undefined FrontPage tsx:20
>03.03.2003 FrontPage tsx:20

I don't know, guess I'll just try this again tomorrow.

Am a brainlet, what's the commonly accepted way of solving the issue where 2 users check out a resource for editing, and one user submits their changes before the second one? Override the first user's changes anyways? Have some kind of alert to notify the user to refresh?

import { useEffect } from 'react';

const functionalComponent = (props) => {

useEffect(()=>{

if (props.foot) {

console.log(props.foo[0].bar);

}

}, [props.foo]);


};


or something similar, play around with it

Is react reactive like rxjs, what I mean is can I use rxjs with react or is it unnecesary?

looks cool

Thank you so much, it works even if I don't understand why and I'll take it at this point

Anyone have a list of project that I can work with HTML and CSS? I'm learning but, really dunno what else to do.

learn.freecodecamp.org/responsive-web-design/responsive-web-design-projects
You should probably learn some JS.

Still working on the HTML and CSS. Thanks user helps tons. Is PHP still being used? I need a side hustle and was wondering if making Wordpress plugins be getting a yung foo's guap up. Thanks

Yeah, it's still pretty popular. Especially with frameworks like Laravel, Symfony and stuff.

Dont let 2 users check out the same resource

What's the average load a shitty WAMPServer can take?
I've never bothered to check how many resources does a page need.

>javascript
ew

Wouldn't the user's end have to keep checking continuously in order to see when the resource is freed up?

Does somebody have the learning resources for PHP that used to be in the OP?

Only check the status when theyre trying to check it out

Learning Redux... man what kind of autistic inhuman crap is this. I've really enjoyed learning React so fart, but this shit is straight ratraded.

So the reducers are just kinda... whatever they need to be? Seems like a really good place to use a model. Maybe I just don't quite wrap my head around it yet.

Regardless this shit seems really janky and there's no way in hell it's going to become anything close to standard.

Yeesh.

Reducers are just functions that handle state change senpai.
The reducer gets the current state and a action, given the action.type, you get the new state.

I barely know how to webdev but I have a pressing question. I want to write a simple app for learning resources for a popular video game (gib in-app banner ad monies), so I'm looking at learning the trifecta of webshit so I can easily work with both android and iOS. Question is, should I serve the content from an https server or just bundle it in the app? What are the best practices for that sort of thing? Would serving it remotely speed up pushing updates for new text/images/videos? Would bundling it would just cause headaches???

Attached: il_570xN.601914992_cc2s.jpg (570x570, 97K)

Also, it's kinda standard in React now, see useReducer hook.

If I want to host a bunch of dynamic websites on one host, should I spin up a VM for each site and use Nginx to route to the correct VM based on the domain? Or is there a better way to sandbox them(Docker)?

>(You)
OwO

Let's be friends UwU

redux isn't react

Reducers are for maintaining the state after an action fails, completes, or is pending. Usually all you need to do is handle the payload in the action's completed reducer code. Otherwise you want to maintain the state as is

Thanks, that really boils it down. I guess I had the idea that the state needs to have a rigid structure. Which maybe doesn't hurt but I can see that's not necessary insofar as what Redux duz.

Thanks, I'll look into it. This toot is pretty up-to-date, so I'm guessing they'll get into it.

How exactly do you get a virus in a server?
Even if you could freely upload shit into it, how do you execute it?

Exploits or network-based attacks(worm)

What is /wedgie/'s opinion on Wordpress and other "even a retard can do it" services?

Fuck it, gonna learn PHP and knock out Wordpress plugins

good decision

learn laravel for some freelancing too

Most people don't want to do it

So I making an app with vue where you can buy and sell things (its a little game). right now I am adding in a 'favorite' system so items you favorite are put into a list for that at the top of the page. I have it working as intended for one page but on the other page it only updates when you reload/return to the page.

I am using computed methods to filter the objects in the array. each item has an favorite element with a boolean value that gets toggled by an icon. when watching that element in the vue tools it does toggle from true to false but the page doesnt render to match that because the computed filters arent running.


anyone here know about issues with vuejs computed properties?

How does Jow Forums generate filenames? Does it just increment a global counter? What is a good way to generate unique filenames for files being uploaded to your server?

Db id? Also if you need unique names that's what UUID is for

I have a system design problem. The system i've been working on is OO where all objects are initialised at boot. The system has no state and all variables and functions only manipulate the class objects they are in. Now building a relational database to store configuration data using typeORM entity model but im unsure how to relate these to my existing objects. I'd like it to be similar to the existing system but when updating instance variables the db also updates accordingly. Whats the standard practice? extending entity class with runtime class and adding hooks manually to db? what do you even call this architecture? its not MVC i don't think.

Attached: 1552115958270.jpg (949x678, 228K)

I think it's just a timestamp

how to message a specific visitor on my site?
like open a pop up live chat

do you want to embed a third party chat platform(easiest) or do you have your own?

for a third party chat platform ive used freshworks.com/live-chat-software/features/
they have a 30 day free trial and then depending on your traffic you can either stay free or pay.

Anyways as far as messaging a specific customer it depends whether they have an account so you can persist messages across their sessions.

no i just want something simple to ask a spammer what browser s/he's using

use socket.io and once his ip connects trigger a pop up to exchange messages?

>paying for feature
lol ma sides

Enjoy boring yourself with shitty stuffs.
Nah, learn AI, deep learning and MATH.

> ask a spammer what browser s/he's using
Just look at their user-agent? What on earth do you even want to do?

could work

learn to code (joke)
i'd like to see how to interact with a visitor

Do most servers still run Linux? Asking cause i have a flask backend which uses quite a lot of C++ libraries, problem is i am running windows on my "coding machine" with Visual Studio so i can't compile to .so, only to .dll, which wouldnt be a problem if i found a cheap windows hosting machine for a websites

Attached: 367373467.jpg (477x477, 41K)

Any standard calculations on figuring out how much processing power a website needs?
Like if you are trying to run multiple independent websites on a single server.

Why do people use PHP for freelancing $5 sites when Node is better and easier

I don't want to end up being a sysadmin for a client who's spent $5 on a site. or even $500, which is about as low as I've ever gone. It's not worth my time. So uploading some files to a cheap shared server instance and pointing a domain name at it is simpler to get your head around than getting them to spin up a heroku instance or whatever. It'll change as things like netlify become better known but for now it's still just the easiest way.