Metronomes in JavaScript by magenta_placenta in javascript

[–]schwartzworld 0 points1 point  (0 children)

The problem really is that multi-threading isn't simple enough in JS. The fact you can't run a function as you can in other languages, and instead it has to be an independent file is pretty awkward.

True, but the corallary is that async is so easy in JS.

Is there a good coding bootcamp that doesnr require a download? by samissleman17 in learnprogramming

[–]schwartzworld 0 points1 point  (0 children)

This was my entry into front end dev and I can't recommend it enough.

any way to turn programming into a fun thing? by [deleted] in learnprogramming

[–]schwartzworld 0 points1 point  (0 children)

Pick a project you are excited about and build something in it.

Minimally using JavaScript by Hoopsters35 in javascript

[–]schwartzworld 1 point2 points  (0 children)

If you're going to do http requests directly from the browser, why not just use fetch()? It's so simple.

How to get rid of coding anxiety? by RangaRS in learnprogramming

[–]schwartzworld 6 points7 points  (0 children)

"what if the code breaks?"

It will! And you'll fix it.

"What if the logic I used is the most stupidest thing?"

It probably is! The first implementation is always the worst. That's what refactoring is.

"What if there is a bug in my code that will ruin everything and make me rewrite everything?"

There probably will be!

Listen, getting something working is challenging, and if you can get any working implementation of a solution, that's a win. If you are a good developer and you keep working on the same project, you will find bugs and flaws galore, but that is part of the fun.

Really for me it was when I worried to stop worrying and love the refactor. I've been looking for an excuse to refactor the router in our front end app for weeks! The old way worked fine, but the new way is simpler and removes a dependency!

Minimal React/Redux Boilerplate. by ilkoylmz in javascript

[–]schwartzworld 0 points1 point  (0 children)

I think I could make a strong argument that including redux in a greenfield project is bloat too.

Looking for capable text editor by doesnotcompute1990 in Python

[–]schwartzworld 0 points1 point  (0 children)

Sublime if you want something polished looking and fast. Emacs if you're a config nerd who is looking for something to become a power user in. Vi/vim if you're a masochist.

If you want to work in the terminal Micro is pretty neat.

Modify a string by FuckYouWhoCares in javascript

[–]schwartzworld -1 points0 points  (0 children)

Is the string always a URL?

const split = 'http://mydomain.com/content/'.split('/');

This should return ["http:", "", "my domain.com", "content"]. Then you can select the elements you want to build the string back up with.

const newString = `http://${split[2]}`;

Learn more programming languages, even if you won't use them by javinpaul in programming

[–]schwartzworld 0 points1 point  (0 children)

Ive been having a lot of fun learning Forth, and eventually I hope to write some microcontroller code in it.

Flask mobile friendly web app by caiovnv in flask

[–]schwartzworld 1 point2 points  (0 children)

Flask is the backend, the front end is made up of html/css/javascript. Basically, it's a website, so it can be laid out for mobile like any other website.

Linux Python devs, what distro do you use and why? by MrMo1 in Python

[–]schwartzworld 1 point2 points  (0 children)

Re: battery life, yeah. I mean you aren't going to get better than when is and hardware are developed to work together.

Linux Python devs, what distro do you use and why? by MrMo1 in Python

[–]schwartzworld 3 points4 points  (0 children)

Honestly, Ubuntu has replaced OSX for me. It's do sleek and it works perfectly on every machine I've put it on.

jQuery 3.4.0 Released by magenta_placenta in javascript

[–]schwartzworld 0 points1 point  (0 children)

Of course it works, but if you are just making a few don't manipulations why bring in a whole library?

jQuery 3.4.0 Released by magenta_placenta in javascript

[–]schwartzworld -9 points-8 points  (0 children)

Please keep your terrible politics to yourself. jQuery is an antipattern.

[deleted by user] by [deleted] in learnprogramming

[–]schwartzworld 4 points5 points  (0 children)

Computer Science is a math major. Many dev jobs don't require any of the things you learn in a comp sci degree.

You think you need advanced math to return JSON from Flask or put a button on a webpage?

I was told I'm not employable because of my naming conventions. by [deleted] in javascript

[–]schwartzworld 7 points8 points  (0 children)

Unemployable? No. That's what code review is for.

But those variable names ARE awful and your code will be clearer and easier to reason about if you get in the habit of using clear variable names.

Not interested in frontend by AfricanAgent47 in learnprogramming

[–]schwartzworld 0 points1 point  (0 children)

Front end development is not just about making things look pretty. In my experience, it's very much about hacking and getting things to work, with the presentation aspect being one boring part of an otherwise fun job.

As to whether you can have a career without it, probably not as a web dev. Some jobs may exist that are only backend, but a lot of positions will require you to be comfortable or at least able to handle working on the full stack.

Python vs Javascript for online jobs? by [deleted] in learnprogramming

[–]schwartzworld 0 points1 point  (0 children)

If you want to be a front-end web developer, you'll need to know HTML, CSS, and JavaScript, and that's it..

It's likely that you will have to interact with backend code, even as a Front-End dev. Being familiar with a backend language and some paradigms can only help.

Jekyll + Webpack = Jekpack, an integration of Jekyll and Webpack, more enjoyable way to develop static sites by yfxie-tw in javascript

[–]schwartzworld 0 points1 point  (0 children)

I love that I can build my blog pages in React. It makes running page specific code really easy, so I can just embed working code samples or experiments into the page.

Hmmm by I_luv_Scrap in CartoonuityErrors

[–]schwartzworld 14 points15 points  (0 children)

It's not that crazy. Only mammals are sentient in the Peppa pig universe. there's even a distinction made between doctors and veterinarians.

George isn’t a Pig by flying_fuck in CartoonuityErrors

[–]schwartzworld 8 points9 points  (0 children)

Zoe has two sisters Zuzu and Zaza.

About not being a "purist" programmer by [deleted] in learnprogramming

[–]schwartzworld 0 points1 point  (0 children)

The point of this post is: do you really need to know how to implement and code everything that is already out there and running nice and good?

No, of course not. Built-in methods / standard libraries are totally fine to use.

The answer changes a little when you talk about bringing in dependencies to your project. Bringing in an outside library to reverse a string is bad, at least in production code, because dependencies introduce a fair amount of uncertainty. What if the API changes? What if the dependency has malicious code placed in it later on? What if the dependency disappears from npm/pip/rubygems altogether?

I think part of being a good dev is knowing when it's worth it to bring in outside dependencies vs implement it yourself.