For the best experience on desktop, install the Chrome extension to track your reading on news.ycombinator.com
Hacker Newsnew | past | comments | ask | show | jobs | submit | history | developeron29's commentsregister

Nice read. I've seen similar mudras represented in a buddhist temple. Wonder if they are related


Agreed 100%. Communication is key. QA and Devs should always be part of the same team and have no communication gaps


In one of my previous companies, Our workload as developers went significantly down, code quality went up and bug complaints went down after we hired a QA team, as opposed to the developers doing it themselves.

It is important for code to be looked at and tested with a fresh perspective

and that's what a separate QA team aids in


"The benefits of internet far outrides its shortcomings"

Stop being pessimistic


Not if you're good at it.

"If you think something is hard or not, both ways you are right"


"When you don't pay for a service, you are the product"

Never realised they'll read my code to make something like this and maybe even make profit from it.


Reminds me of the movie Antitrust (2001), where an evil company, modeled after Microsoft, is surveilling programmers to steal their code.


Yes Jquery does makes things easier than vanilla JS

Best being

$("#id") replacing document.getElementById("id");

Makes code look cleaner


https://developer.mozilla.org/en-US/docs/Web/API/Document/qu...

Does the same as the $ query but native in every browser in IE9+ and gives you a native node. Also more performant than getElementBy<whatever> methods.


document.querySelector(selector) is more typing and more visual clutter on the editor screen.

jQuery is elegant, concise, and was designed by a genius. The "modern" methods are ugly, verbose, and were designed by a committee.


`const $ = document.querySelectorAll.bind(document);`


You can define your own `$` function. This way you can have the clean code without the entire jQuery library

    function $(arg) {
        if (arg.charAt(0) == "#") {
            // HTML spec does not support ids to start with numbers [0]
            // (you may not need this conditional on your website)
            return document.getElementById(arg.slice(1))
        }
        return document.querySelector(arg)
    }
Using this function you can select your comment with

    $('#27677234')
jQuery does add many extra features but if clean code is the only thing you are after there are other options.

[0] https://www.w3.org/TR/html4/types.html#type-id


The HN js actually does just this. The file isn't very long but has some great functions at the top

https://news.ycombinator.com/hn.js


True, but jQuery does a lot more than just id selection with $!

You could just extend the function to detect '.' vs '#', and do a class selection as well. And then add all of the selectors, subselectors, etc. (similar to, but far more powerful than css3's selectors.) and if you go far enough, you reinvented zepto (but still a long way from jQuery)

(actually, since $ is basically synonymous with jQuery, it'd probably be better to choose a different function name. too bad you can't define it as #(id).)


> True, but jQuery does a lot more than just id selection with $!

Yes. For a high degree of jquery-compatibility, you can use my library.

    const $ = document.querySelectorAll.bind(document);


This comment made me spit my drink out. People forget about bind, it's nice to replace the old closure patterns.


I pivoted to create a search engine for cryptocurrency instead as current solutions for crypto price change comparison like coinmarketcap or coinranking, seems to do the job well. Thoughts?


Hi community!

Always wanted a site where i can lookup present and past price trends of most common cryptocurrencies

Couldn't find the easiest one to use so built one

Let me know your thoughts, Thanks!


Thanks! great advice


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search:

HN For You