<wdg/> - Web Development General

Prev thread:
>Free beginner resources to get started
Get a good understanding of HTML, CSS and JavaScript.
developer.mozilla.org/en-US/docs/Learn - a good introduction (independent of your browser choice)
freecodecamp.com
codecademy.com
hackr.io

>Further resources
developer.mozilla.org/en-US/docs/Web - excellent documentation for HTML, CSS & JS
github.com/kamranahmedse/developer-roadmap - Frontend+Backend learner-path suggestions
youtu.be/Zftx68K-1D4 - Web Development in 2018

jsfiddle.net - Use this and post a link, if you need help with your HTML/CSS/JS

Attached: wdg2.png (822x552, 868K)

Other urls found in this thread:

java-performance.info/base64-encoding-and-decoding-performance/
youtube.com/watch?v=PyI3_cw9OWA
facebook.github.io/react-native/docs/flatlist.html
jwt.io/introduction/
twitter.com/SFWRedditImages

First for don't criticize my design decision because I don't fucking care.

then don't ask people what they think

If I am making a very simple portfolio site, what kind of framework or library should I use if I even need to use one?

Third for post your design shit and I'll improve it tenfold in just 10 implications.

I didn't.

I showed someone at work a site I launched and the first thing they did was break down how the design could be better. I'm fine with it to an extent because critique is good for learning, but then he brought out the school card. OH IF YOU HAD GONE TO WEB DESIGN SCHOOL THEY WOULD NEVER LET YOU DO THIS.
So I threw out that his "design school" had him using Dreamweaver, and design isn't a set thing. 10 years before he went to design school people were using framesets for navigation with animated gif buttons as the design standard of the time. Also he went to web design school 5 years ago and his portfolio looks like it was made with tables instead of divs.
Then he mentioned the same 2 design issues 3 times throughout the day. THREE TIMES.

Oh well people are going to do that for the rest of your life. You kind of either gotta get over it or stay mad the rest of your life.

man your work must have been complete shit lmao

nah, it looks better than anything I've seen posted here for the last 2 years.

not exactly a high bar sis

Reminder that you can't be taken seriously as a web developer if you don't have a Macbook Pro.

Reminder that MERN is the way to go.

jokes on you, we use macbooks with Windows running on Parallels

don't those thin mac books overheat when running that?

Is encoding/decoding base64 files taxing to the CPU?

>You mean someone else hosting my bundle, instead of hosting it myself on my website's server?
Sorry, I thought you were talking about an S3 hosted CDN or something.
When you're using Webpack etc, the CDN hosted stuff is usually internalised though you can always link it from the html I guess, that depends on the library.

>are amazon web services extremely confusing
No but if you don't know what you're doing then I guess there's a learning curve. If you understand the technology then I think it's reasonably straight-forward.

java-performance.info/base64-encoding-and-decoding-performance/
seems like it takes less than a second to encode/decode 200mb

Hope browsers too

So after developing a solid understanding of base JavaScript concepts, where can I go, and how do I learn to actually apply the knowledge and build useful extensions to webpages?

I have a reasonable understanding on variables, closure, functions, async, arrays, objects, etc. I just really don't know how to apply that to an actual problem. For example, I want to create a dragging, floating iframe embed of video content. Actually inserting that iframe into a reasonable position in the page, using only JavaScript seems hard to do. I know that I can create elements with the usual document.createElement, set IDs/Classes, and have CSS style those elements. But I don't understand where or how to insert those elements in an appropriate place in the DOM tree.

I just want to build actual applications instead of studying the language's concepts but never actually putting the language's concepts to use. Advice?

Sorry if this is an inappropriate or garbage post, by the way.

Attached: 1522594316056.gif (500x500, 1.03M)

Start building
Literally what the fuck else are you going to do?
Do you want a step by step guide on how to breathe too?

noob question here. is there a special designed way to generate nodes from a server response within javascript? right now I've got html content between ' ' being inserted within a for loop that iterates a json array, but it seems kind of hacky.

>gf wants to learn python for actuary jobs
Anyone here have any good teaching resources for Python? Maybe like curriculum I could steal. She wants to do UI stuff as well (html/css) and so I told her we'd end the Python course with some kind of web project. Is Django still the go to or nah?

Attached: dangeroustogoalone.jpg (570x392, 44K)

Anyone here work with Facebook's graph API? I'm having trouble getting group feed posts, which I need permissions for but in order to submit it for review to GET those permissions, I need to show them it works. Which makes no fucking sense to me so I have no idea what I'm supposed to do

automatetheboringstuffwithpython
the ui stuff is iffy though like sure she can learn html/css stuff but that's generally very basic
at that point she has to decide if she really wants to go into actuary or web

>tfw no qt coder gf
But seriously, as much as I (a MEAN stack guy) know, Django's still pretty popular as the de-facto server framework for Python. As with any language tho, just encourage her to keep practicing it daily.

She doesn't know yet. I might hold off html/css until later. After we complete this course, we can probably move on to sql.

Yeah, I'm going to be giving her actual assignments. When she taught me Korean, she did strip grading (she'd strip a piece of clothing off for each question I answered right and put a piece on for each answer I got wrong). It worked for me, but I don't think it'll work the other way around lol.

you dont need to hold off html/css, as I said she can still do a lot with the basics there (enough to present her stuff if she was into it)
but yeah the actuary/web paths are very different
if she enjoys the html/css stuff way more than the python stuff then it's probably a design/ui/ux life for her, if she prefers the python, she could still get into web through backend, data science, or actuary paths

she just needs to study it for a month and she can land a 100k job in california.

>$ffmpeg -i $input -deinterlace -an -ss 00:00:05 -f mjpeg -t 1 -r 1 -y 2> $target
what did I do wrong? $ffmpeg only produces 0 byte JPEG at $target

what are you trying to do ?

get a frame from a video?

> 2> $target
Why are you writing out stderr?

We live in Seattle, lol.

Do you have any good resources for Python programming exercises/challenges?

yes, automatetheboringstuff (in python)

Yes

it worked in windows

Didn't see the questions at the end of the page, thanks.

>We live in Seattle, lol.
Remote work.

I'velearned the fundamentals of Html, CSS and the basics of JavaScript, but I have no idea of what do make for my portfolio.
I only have a bio of some politic and a tool that gives you back a youtube link with the time you want to start the video when you input the link and the hour/min/sec, but I don't feel I can impress someone with only that.

Is there another way to set an output target? I don't really know ffmpeg. And I'm not sure /wdg/ is the best to ask about it.

Yes and they get progressively more difficult and demonstrate IRL impact so she's not dealing with abstracts 24/7.

>liberal arts degree
>studied ruby for 7 months
>110k job

why do you work with babyscript Jow Forums?

It gets warm but it's relatively k. Obviously I only use windows for VS. Otherwise, I do everything else mac side.

> very simple
> portfolio site
> what framework

The absolute state of web design. Use HTML and spend all the time you saved getting paid by someone else to fuck around with frameworks.

>spend all the time you saved getting paid by someone else to fuck around with frameworks.
I don't quite follow this sentence structure

Ruby is a good language. I definitely recommend learning it. I use PHP and enjoy my job. It doesn't earn even half of a 110k salary but I do. Tons of remote jobs hire for Ruby. I'm learning it alongside React if I ever want to move in that direction, but honestly my job is so chill. I work with an old codebase. I can arrive at work whenever I want. I'm never micromanaged. I can leave work whenever I want. I can work at home if I want. I can take as many sick days as I want and make them up whenever (they don't check, can just pretend I worked a weekend, lol). It's comfy.

Not saying you can't do that with Ruby, but just my situation. Ruby is fun to learn though.

If you're new then learn Ruby and your job opportunities are endless that way.

Use HTML (and nothing else, for the portfolio.) Having saved time (not fucking around with frameworks for the portfolio), you are now available to spend more time getting paid to develop other websites. In the process of fulfilling those jobs, you can get paid to fuck around with frameworks.

Ruby is dying, dont learn it unless you want to maintain legacy code with no chance of an career once your company inevitably rewrites the software from scratch

I was really surprised when I was learning it how negative people are about it. People act like there are no Ruby jobs when in fact it's one of the highest paying languages.

There was a fad for several years of it being used in start ups. Those start ups aged and now they have codebases and established business that require quality ruby devs.

Plus... it's just a gorgeous language to use.

you mean don't be a retard and learn more than one language? no shit. the actual language doesn't matter that much. if you're a halfway decent engineer.

I have no hate towards it. I stand with my belief that if you want a job in a state making 6 figures that Ruby is the language to learn. The only downside is that you have to work in a lefty state and give your money to people that would rather party on the weekends than learn to make money. Also no guns or any other freedoms and you're looked at shitily because you're white and you only got there because of your privilege even though I know a girl making 100k at a job I wanted with only 1 month of html knowledge and didn't even have to build the gigantic super complex website I had to just to apply for the job.

you sound mad, did someone fail a phone screening?

I would just learn Kanban, Agile and Scrum.

300k starting.

youtube.com/watch?v=PyI3_cw9OWA

Can I do web dev stuff purely on VS? Or is that just for dot net stuff only?

You are criticizing him for using Dreamweaver, shitty tech, but cry about being called out on shitty design.

An IDE typically includes a text editor, e.g., VS. So yes, you can. I create js components, css/less, and HTML files with it all the time.

confirming, I don't leave visual studio for development outside of debugging js in the browser

why are those adults playing with LEGOs?

Legos are awesome. I should go get mine from my parent's house.

I am aware of the term lifting state up in react, seems to be usually when a dumb component is passed down props and when changes happen it calls functions in the parent component to change them. But what about when both components are smart? I have this parent component which will be the meeting point, but a child component can be repeated multiple times, I want that child component to hold an object in its state and pass that state to the parent component's own state, which will store it in an array of objects. Is this a normal behavior in react or are there better ways to do it?

Why not have the parent component just store the child components data that you'd otherwise put in the child state in a map on the parent's state? You then aren't hooking in to the react component lifecycle on every component.

For example, look at the code from the link below. Every list item could have its own state with a "selected" property but it's stored on the parent component instead.
facebook.github.io/react-native/docs/flatlist.html

Guys i need help
it wont insert in mysql although it says that the registration succeeded

$encrypt = crypt( $pswd );
$reputation="new";
$lvl="member";
// Insert the new user into the database
if ($insert_stmt = $mysqli->prepare("INSERT INTO users (email,pswd,name,lname,number,adr,reputation,lvl) VALUES (?, ?, ?, ?, ?, ?, ?, ?)")) {
$insert_stmt->bind_param('ssssiss', $email,$encrypt,$fname,$lname,$number,$address,$reputation,$lvl);
// Execute the prepared query.
if (! $insert_stmt->execute()) {
header('Location: ../index.php?error=Registration failure: INSERT');
}
}
header('Location: ./index.php?msg=You have been registered to !');
}[/code

you need to return after setting the header otherwise the script will continue running.

Try output the error.
die($insert_stmt->error);
after execute()

I've never failed an interview.

nothing comes out

Eat more fibre

When two components have state which depends on each other, change your design such that the two components take that data as props instead, and have the state managed by their shared parent. That is what "lifting state" means.

The shit?

By the way, stupid question, but is there any function to dump available jquery functions but not that is built in jquery itself?
Typing jQuery.fn or $.fn to console dumps all available functions, but it dumps all of them. I need to see just the plugins.

how do I leave webshit

dont use mysqli. use pdo.

ssssiss is only binding 7 parameters, you have 8. But also switch to PDO if you can, it's much nicer to use.

okay ill rewrite it to pdo

it's nginx easier than apache? i usually try to install apache + php manually but i'm having some problems to make it work with laravel, should i try nginx? (windows 7)

What did you lot do and create? All I'm hearing about web dev is that you need a macshit...

OK, but how would I go about dynamically adding more objects to the state? I basically have groups of inputs that want to dynamically add as the user clicks a button.

state = {
thing: '',
array_of_objects[{
text: "",
more_text: "",
// add objects dynamically by user click
}]

// Maybe like this?

handleAddObjectInArray = event => {
event.preventDefault();
this.setState(prevState => ({
...prevState.array_of_objects.push({
text: "",
more_text: "",
})
}));
};
}

// Now, how to know how many input groups do I need?

const listOfInputGroups = ???.map(() => // map this to what? The number of objects in the array maybe?

);

Yeah you literally can't write in a text editor unless it's Apple certified, go buy that MacBook Pro™ or just give up.

It can't be an old one though you need to spend as much as possible because more money makes the code faster.

You need to go look up the map function to start with.
And then look up appending/inserting elements to the DOM.

Once you understand the map function, you'll understand how you build an array of elements.
Then, google for examples on adding elements to the DOM, there are many out there.

Im looking to move to another server so ill be reinstalling everything

apache2 or nginx?

I get about 300 - 3000 users and 200 - 1TB / day

Its just basic html and video files

Attached: mm.jpg (1670x930, 158K)

This but unironically
All web dev tools are made by and for Macbooks, and the whole ecosystem is vastly easier to handle. Everything just werks. If you don't have one, maybe apply for that burger flipping job instead.

>web dev
>the whole ecosystem

-Vim + emmet
-Command line for launching test server
-Browser with debuggin tool for checking


user, I'm not really sure I understand what you mean..

How do I make sure that one and two characters fill the same amount of space in css?

Basically I want the padding after them to be EXACTLY the same?
So
__1__
__2__
_10__
_51__

Just import leftpad.js, mate.

Works like a charm!

put each of the numbers inside a container with a set width

nginx

monospace, text-align: center, align-items: center;

a SPAN specifically

It's time to stop

How do I

it's tradition

>mfw some people don't use a MacBook Pro™ for web dev

Attached: 1399054610049.jpg (451x392, 81K)

>All web dev tools are made by and for Macbooks
Like what? There's Sketch, but that's not by any means a necessity for web dev. Nearly all the shit I use is cross-platform, or has an equivalent on other OS's.

Sketch is also by no means the only option there either. Adobe XD is great, Figma is great. Both free in comparison too.
We just have a dedicated shitposter who needs to rationalize spending money instead of actually just working.

Man,I don't have a MacBook Pro. I only have a laptop with this specs

>Core i7-5500U 2,40GHz
>8GB RAM
>2TB HHD
Nvidia GeForece 940m 2GB

What does it has that my laptop doesn't?

I'm trying to figure out which would be the best way to model a mongodb relationship for a blog cms. Should I use separate collections with references or embedded documents?
The blog cms would have multiple users with different roles, blog posts with comments, likes and so on. Basically a node js/express/mongodb version of WordPress.

Sketch is the only reason I haven't installed GNU+Linux on my Macbook, even though I only use it once a year to find colors and fonts.

>non Apple user

I bet this guy can't even fizzbuzz in CSS how do you even expect to get hired it's pathetic

Attached: me.jpg (233x216, 7K)

jwt.io/introduction/
>In authentication, when the user successfully logs in using their credentials, a JSON Web Token will be returned and must be saved locally (typically in local storage, but cookies can be also used), instead of the traditional approach of creating a session in the server and returning a cookie.
But you'd still have to save the token in a session regardless, otherwise you'd have to save it in the database which would be much less efficient, right?

Attached: jwt-diagram.png (1334x748, 81K)

I need advice.

I want to host a web service written in python (Hydrus Network) and another stack of software written in Java, Go and C#. In other words, I need a VPS.

I will potentially be hosting a lot of data from this site, but I am unsure. This data MAY include data like lewd anime images and similar.

What are my options concerning legality? I don't intend to allow people to upload content, but it will be retrieved via several automated routines.

Can anyone recommend a stable host that'll provide a lot of bang for my buck?

What? No, only the user keeps the token and sends in in headers.

so it's based on the principle that if you can decode the JWT with the server secret then it is considered a valid token?