arr.forEach(function(pageID, index, array) { var url = 'fullurlgoeshere'+pageID; console.log("Opening page "+url); page.open(url, function (status) { console.log("Inside"); if (status !== 'success') { console.log("Failure!"); phantom.exit(); } else { console.log("Waiting..."); window.setTimeout(function () { //console.log(page.content) console.log("Creating first file"); fs.write(pageID+'.html', page.content, 'w'); }, waitTimeInMS); // Change timeout as required to allow sufficient time } }); }, this); Why in the fuck does this loop over every item in the array immediately, then close? It doesn't block or wait on anything. I'm trying to make multiple page scrapes in sequence instead of opening and closing the JS server for each page. The logic works totally fine if I take out the loop and only pass in a single page.
Blake Powell
should I go to kode kamp or get a degree?
Thomas Bennett
Nevermind, it's because I had the exit clause right after that loop. No fucking idea why that's executing right away though.
Is there some way to block that call until everything in the loop executes?
Cameron Parker
>that callback hell
what's the problem? It runs and closes immediately? Maybe page.open doesn't buffer calls so it spazzes out. Rewrite it so you don't call page.open again until after it gives you a result
Camden Ross
Yeah it just spits out "opening page blah blah blah" for every URL I want and then immediately kills itself. Doesn't matter if the exit call is inside or outside of the loop either. I have no idea wtf is going on, I never write in javascript, I just need this because the pages I'm scraping are dynamically generated so I needed something to open the DOM and wait a second before spitting out the page.
Again, it works perfectly fine if I take out the loop, but I don't want to be starting up a new process for every single page
Colton Morris
const promises = arr.map((pageID, index, array) => { let url = 'fullpagegoeshere' + pageID return new Promise((resolve, reject) => { page.open(url, status => { if (status !== 'success') reject() fs.writeFile(pageID + '.html', page.content, err => { if (err) reject(err) resolve() }) }) }) })
Promise.all(promises).then(data => { //do work with data here })
try something like this. you're dealing with lots of asynch shit and doing it wrong.
you need to make a bunch of promises and resolve them only when everythings ready, then use Promise.all on the array of promises to make sure they're all done
Lincoln Butler
[Embed][Embed][Embed]
Josiah Gomez
How can I make a list in HTML that looks like pic related? I'm new to web design, I'm usually just a programmer but trying to make my own webpage.
Xavier Cook
List:
Item Item Item
Something like this probably. I didn't test it
Charles Brooks
.benis { display: flex li { list-style: none; } }
List:
Item 1 item 2
Connor Collins
This one worked, thanks!
Owen Ortiz
1. Will I get the skills needed to start working from FreeCodeCamp? 2. How much should I expect to earn as a web dev from South America working remotely part-time?
Jeremiah Powell
None of you guys actually do web-dev using PHP anymore, right? I mean, nobody can be that autistic.
Oliver Rodriguez
Follow your passion and try to fit a degree in but don't over pay.
Joshua Collins
What sort of applications are you guys using a frontend framework like react or vue for?
Ryan Russell
Materialize on the web and with electron
Dylan Lopez
stay koding
Austin Ward
I want to point out that the video you have posted, if you check the person's website it has all sorts of issues, like no scaling properly, menu not working, also the videos suggestions are questionable at best.
Adrian Jackson
i want to get into web development but i only really know C++ and a little bit of python
can i do ANYTHING web related with my current knowledge of C++?
Oliver Torres
how about you stop being a lazy shithead and learn some webdev languages?
Anthony Evans
>C++ and a little bit of python you can learn any non-functional language with ease (you'll probably want javascript at least) once you get past the syntax differences and the couple gimmick features that make a language ~unique~ it's all written the same way in the end
Colton Butler
There are a few c++ web frameworks out there but they aren't used very much in the real world. Python on the other hand is very common and you'd probably be much better off diving deeper in that.
Carson Smith
reconsider. the most exciting thing you'll do in web development is query a database and put the information into a html file. Go learn qt, you're halfway there.
Aiden Green
how is that autistic? using assembly or coq for webdev is autistic, not php
an application that calculates and servers some sport stats, charts and match results
Kayden Sanders
I like Vue
Julian Cox
Just got a £15k wordpress project in that's a week of work. I'll drop shit languages and libraries when people stop paying me to use them.
Jayden Peterson
if i make my own webdev 'company', how hard is it to get clients?
Nolan Bennett
how long is a piece of string?
Dylan Russell
Alright fuck it, gonna learn WordPress development. Any tools I can use?
Chase Anderson
wordpress
Connor Morales
Aspiring webdev here How to get job?
Nolan King
Do all the courses in the OP. When you're done with that, come back and ask again.
Juan Cooper
1. no 2. $20/month
Nicholas Fisher
juan. si chu. treinta y siete pesos
Lucas Morris
>NEET guide to web dev employment That should probably be replaced. It hasn't been updated in 2 years.
Lucas White
Stop giving them ideas! Let them think Wordpress and PHP are shit so there will be more jobs for people like us.
Evan Peterson
>when you finally achieve react server-side rendering with just the cross platform v8 interop library and it's faster than MVC and react.net Dunno what to do with this. I'll probably never get credit if I release the source, people never donate.
Also there's another guy here that's already done this.
Levi Nelson
Depends on what your market place is like in SA. If you're trying to get hired by a USA based company then you're fucked unless you have legal clearance to accept work inside their country (trust ne, I've been applying for remote jobs as a non US citizen for over a year now). Feel free to do work on sites like Upwork and Freelancer though, you'll probably just make enough to survive once you build up a reputation on those sites.
Gabriel Campbell
Venezuela. I'm fucked.
What if I send emails to random European startups?
Luke Ward
win7 or win10 for work env fellas?
im coming from ubuntu because im gonna into old school emulators im thinking win10
Christopher Davis
10 because WSL
Luke Anderson
>WSL good shout
Michael Lewis
que tal amigo. No es imposible, siempre hay empresas que ofrecen VISA sponsorship:
Claramente no son la mayoria, pero existen. Tambien conozco otros sudamericanos que hicieron competencias (hackathons, etc) y les fue bien, y a partir de ahi fueron contactados por empresas europeas. Pero para eso tenes que ser muy bueno. Si te lo propones como meta a largo plazo y te esfuerzas, se puede.
Y mientras, freelance a traves de UpWork o algo asi, para juntar experiencia.
Juan Hill
heast du oasch, es is ned grod freindlich in irgendana ondan sproch auf ana multi kulti seitn zu schreibn, so bleib bei englisch du brunzn.
Dylan Robinson
get these wooden toy languages out of here
this is an american imageboard where we speak american only
Jason Martinez
kindly fuck off
Christian Watson
Worried about foreigners taking your jobs?
VISA sponsorship is good yes, but also rare. Still try anyways, if you're good enough they will move mountains to get you on board.
Jose Davis
i am going to hack you now
le anonymouse send their regards
Jace Hughes
Just kind of starting off with this whole webdev thing kinda, I feel like I am. Got some good knowledge in html, css, bootstrap/Foundation, basic javascript concept (never really built anything with it though) and Adobe shits. Basically I'm a web designer (with no experience) that wants to move into dev.
No idea where to go from here. Focus on javascript? I was about to into Rails or C# but wasn't sure which to pick? I know rails is easier but there are also no jobs. C# is harder but job market is better?
What do?
Brody Reed
>I know rails is easier but there are also no jobs. C# is harder but job market is better?
I was faced with the same question and went with C#. Hopefully it'll pay off later on.
Xavier Foster
How are you finding the adventure with c#? Seems like MS actually has a lot of free resources for people to learn it and everything.
Also if anyone else wants to help me figure which path to take I'd appreciate it.
Camden Adams
>How are you finding the adventure with c#?
Visual Studio and C# are pretty comfy, but it is annoying how even the smallest thing requires so much code just to run. The VMC model on C# is just a huge clusterfuck, I think it's too much for newbs like us.
I took a break from C# and am doing Python + Django now, which is a much simpler and transparent language and framework. You learn pretty much the same thing, only the implementations are so much easier. Once I get the grasp of things in Python I want to move back to C# because there are waaay more jobs, but learning basic webdev concepts through C# is hell.
I found a few good books on .Net and MVC, was following along, nice and dandy, but when I tried to do my own thing, I was completely lost. With Python + Django, everything is a lot more intuitive.
Also, those hour-long videos on the .Net Academy or whatever are fucking awful. When you want to go back to see something you got wrong the first time, it's impossible to find the right spot, because they're re-writing the same bit of code over and over again. For me, a book is the way to go.
Aaron Thompson
Should I become a web dev? I'm balls deep in learning C rn but don't think I want to be dull as fuck accounting work for the rest of my life. WD has a more creative flair to it.
Henry Carter
Writing REST Apis in DropWizard/Java, it's comfy pals
Carson Gray
Do what you enjoy doing most man.
John Ortiz
Thank you very much for the write up. Very informative stuff user. I was actually wanting to go the route of rails because it was easy and gives you a good look into the MVC model. But I NEVER see job postings asking for rails.
Python is also an option I suppose, I always forget about it for some reason. The Microsoft videos did sound too good to be true to be honest.
Sounds like C# is more of an intermediate language then. Thank you for putting the breaks on that idea before I got heavily invested.
Eli Phillips
Don't quit your day job. Learn C on the side, branch out into doing dev part time, and if you find that you can make a decent living off it and you like what you're doing then switch to full-time dev.
Wyatt Hall
Same user. Don't rule out C# just yet, it's a very nice language, and the beginner's stuff is the same in every language, so you could easily learn it in C#. Check out pic related, I plowed through it in one week (up until part 4) and all of that, Parts 1-3, are the same in every language.
Also check out CS50x on coursera, the Harvard intro to computer science, pretty good. It doesn't rely so much on the videos because you get all the slides and the transcripts, plus the only thing that matters are the excercises. By week 7 you'll be doing Python + Flask, making a cool website. Definitely recommended just to get started. Go through the first weeks which are heavy on C, but don't get stuck on them if you're struggling too much.
Jason Perez
Don't have a day job, still an unemployed student
Bentley Young
get a day job, and then you'll be ready to follow this guy 's advice
Jaxson Carter
I guess it's not bad advice. I'm still not 100% on what I want to do with my life desu.
Are part-time programming jobs all that common? I've only ever seen typical 9 - 5 offerrings around here, and I'm not sure how I'd go into freelance if that were an option.
Freelancing. You could find clients on your own or do odd jobs on Freelancer, Upwork, etc.
Luis Cook
>Are part-time programming jobs all that common? I wish.
Part time hours at 30 an hour would be comfy and give me time to build my own stuff on my own time.
Lincoln Reyes
I got offered 2 different positions for 2 different companies. One, as a front end developer, and the other as a data analyst.
Which one should i take? Pay is about the same, but i'm wondering which career is better in terms of long term stability and money.
Samuel Lopez
I'm pretty happy being a Wordpress developer. Stay mad.
Kevin Hill
Me too. It's like react and angular had a baby, but nobody wants it.
David King
>Venezuela
Shit, son, I feel sorry for you.
Luis Hughes
>data analyst. this one for sure, because you can use it in any context or industry. Front-end is pajeet-tier. With some data analyst experience, you can go to Google, Uber, Facebook, or any other fucking company in the world.
Juan James
You call yourself a developer? more like plugin installer.
> there are wordpress developers who think making a website with Jquery is "bare bones"
Anthony Lee
What's it like user? I'm thinking of looking into that for a first position. What kind of stuff should focus on? What would impress a potential employer on my portfolio?
Thank you in advance
Jace Rogers
Don't senior developers make a lot of money while analysts will eventually have their pay capped at a certain point? (I have no phd for data scientist).
Dylan Martin
so what's your take on .net core /wdg/
Jacob Foster
I'll take a look at it after it matures and stabilizes
Nathan Mitchell
Im trying to make a website thats mostly user based
What can I use to show how many users are currently using my site, on the site itself.
Jackson Lopez
daily reminder that react and it's siblings/cousins are all junk and you should just use a lisp instead of using an ugly half assed reimplementation of one. or just write plain js.
Grayson Fisher
>working on personal projects while looking for a job in the industry >big dreams >"I can't wait to get a real job in web development and learn while I'm working! I'll have so much more time in the evening to get my personal projects up and running and some day they'll be live and people will use and love them" >get job I want >haven't touched project repos in six months
Thomas Green
Can't ask a question like that without telling us the language and/or framework you're using.
Connor Roberts
wtf I hate react now
>create unique id for each visitor >save it in a cookie >record it in the database along with last visit time >when user opens the page check if a cookie with visitor id exists >if yes then update last visit time for that id in the database >if not then create the cookie as described above >query the database for the count of visitor ids with last visit time not more than for example 5 minutes from now() >that number is your count of online users
Lucas Gutierrez
great post, really opened my eyes. I'm now rewriting react in plain js, although I might just copy their code because it is written in plain js too. would that be ok?
Charles Moore
ha, at least you got the first half of the dream, a job. A lot of us here are not even at that point.
But go on, tell us a bit about the job you got, and if you're willing, tell us about that personal project as well.
Anthony Rogers
What does "paid relocation" mean? What does it cover?
Carson Baker
Differences between Apache and Nginx? Pros/cons, etc
Adrian Turner
they'll probably give you a fixed sum, my guess is between 2-5k euros, and that's it. But don't worry about that now, first get the interview, then you can ask them in person.
Ethan Bell
posting pic related because it's a great guide for back-end devs. Once you're confident in one or two languages, and you can do most things on the Web Server-Docker list, you should start applying to jobs. I'm almost there, /wdg/uys, I'm almost there...
Matthew Turner
How'd you get a data analyst offer? Sounds interesting
Julian Flores
Nothing special. I'm a cs grad who also does web development for fun. Applied to different areas and that's it.
Sebastian Garcia
Depends what the front-end dev is using. Angular? Go for it. Anything else? Take the DA.
Data analyst is fine, but I'm not sure what they cap at. With web dev you can go to being CTO making 400k a year in a startup environment or several million in a larger company after a few decades if you can act the part.
Bentley Adams
The front end position uses angular, but I'm hesitant because it's a small company that basically makes websites for local businesses. Doesn't seem like the company had any more room to grow.
Mason Thompson
React is actually the replacement for razor, it just hasn't realised it yet.
Nginx is what I use, but I doubt it's better. The only trick is that to set up a backend you need a "proxy pass" setting. Set this to the port on localhost your backend is and give it a location, or route.
Because MVC is horrible.
Because we want to build pages with backend data, static html fails and it needs to be rendered on the server. This is where react comes in.
It does mean everything changes. It means writing entire webpages within jsx files. I'm so sorry but this is for the better, MVC and razor must end.
C# gets the "I'm hard, actually not really, idiots just gtfo" thing. It's not a hard language, it's not c++ levels of syntax and it doesn't do the tricks c programmers do.
IMO web dev can be just c#, JavaScript and html thes days. People like c# because it's not difficult and does things on the single digit millisecond time frame rather than the double or triple millisecond time frame most other languages do.
Only because HR people prefer them.
Full circle, this is me.
The only thing people actually want from mvc is getting backend data to the client before the page loads. Last I checked mvc had delay of 30ms, that's fine since anything below 200ms is technically unnoticeable ignorable, but it adds up. Firing up v8, making an object pool and loading scripts, has a delay under 10ms.
Julian Campbell
>People like c# because it's not difficult and does things on the single digit millisecond time frame rather than the double or triple millisecond time frame most other languages do. there's nothing really special about C#'s performance
>Because MVC is horrible. are you talking about MVC as in the pattern or the product called "ASP.NET MVC" (by a company that is the fucking worst at naming and versioning their stuff)?
Blake Howard
No I'm talking about the horrid razor stuff from "Microsoft® ASP.NET MVC WEB APIs." 10 years ago it was probably the thing, because backend data sent when clients first connect, but at the moment everyone seems okay with react so replacing it with server-side rendered react seems to be what people actually want.
>there's nothing really special about C#'s performance Depends what you're doing with it.
That horrid Microsoft framework has delays hidden somewhere that the "pros" know how to turn off for benchmarking and can make ASP.net respond in microseconds. It's all colluderism, even if you're a loyal Microsoft customer cuck they'll still tell you to wrestle with .netcore rather than tell you the setting.
If you reimplement an entire web framework with sockets you'll get similar speeds to Go and Node.js hello worlds. This is basically the minimum if you think there's a chance your site would get hundreds of clients a second. When node is actually executing JavaScript code it starts taking double digit milliseconds, it's at least 4ms to open the engine and something simple like rendering a jsx file takes about 2 or 3 ms.
I digress, for sites with at best one client a second no one actually cares if everything is responding under 300ms. That being said, picking a framework that responds 10-20ms than the alternative is at least a head start.
BTW I don't trust those benchmarks.
Thomas Cook
>React is actually the replacement for razor, it just hasn't realised it yet. The scooter?
Adam Roberts
1. Build a websocket server. 2. Ping users every N ninutes
Ian Jenkins
Razor is a horrid templating language used by Microsoft for MVC ASP that introduces several new syntax characters and when you look under the covers is literally just injecting things places and then sending it as a string.
This is fine because until server-side rendering was really a thing, which really meant engines like v8 existing since clients are JavaScript so you'll probably have JavaScript used for client pages, until relatively recently.
The mindblowingly good idea about react is it does all your html/javascript in one file and is artificially popular because Facebook uses it. Against Razor it's everything you want in scalable web development.
are there any unofficial >best resources for learning node.js? i have around 5 years of on-and-off experience with programming already (mainly java/C#), but i've never done anything involving the internet before
Grayson Turner
Why would I want my html and js in the same file? If that's what you want then just use s-expressions. I'll admit that XHP is cool and is how PHP should have been designed from the get go, but JSX is just not..
Joseph White
The official api docs for learning node. MDN, 'js: the goodparts', and 'js: the definitive guide' for learning js.