HackerTrans
TopNewTrendsCommentsPastAskShowJobs

telesoft

no profile record

Submissions

Ask HN: Does Reddit site performance seem to be getting worse?

3 points·by telesoft·4 yıl önce·2 comments

comments

telesoft
·4 yıl önce·discuss
Humans are wrong all the time. Do we really want "human-like" AI? And maybe this is where everything falls apart: will a machine as smart as a human be prone to the same errors as us?
telesoft
·4 yıl önce·discuss
if you're in a terminal: ctrl + shift + C/V

It has something to do with the terminal but this seems to work in every terminal application
telesoft
·4 yıl önce·discuss
>people were defending them.

I believe that some company monitors websites like reddit and twitter for talk about Monsanto or Big Oil (fracking) and that company pays shills to defend them.
telesoft
·4 yıl önce·discuss
Well it's true for me too. The first thing I do when I get a new laptop is try out windows (it's pre-installed) and of course I want to like it but it just doesn't compare to GNOME3... I always end up going back to Linux. And I have used both extensively and adapted to both work-flows and I'd say GNOME3 is superior once you adapt to it.

No you don't need a minimize or maximize button, they are actually useless in the GNOME work-flow, and unnecessary on windows too.
telesoft
·4 yıl önce·discuss
>My email is literally filled with twitter emails trying to activate my inactive account to temporary inflate their numbers.

Big if true
telesoft
·4 yıl önce·discuss
Assuming the url is formatted correctly:

  strings.Split(urlString, "user/")[1]
https://go.dev/play/p/tWi-Ge0CA1X

That's one way to do it.

>more URL parameters

I thought thats what http.Request.ParseForm() was for (assuming correct formatting)
telesoft
·4 yıl önce·discuss
You definitely don't need a framework to get the user name out of a URL, you need one line of code.
telesoft
·4 yıl önce·discuss
Cool project. I'm currently building something similar to hacker news using only the standard library. How could this project help me?

The way I use the standard library is like a super condensed version of React. Templates are my components. Since templates can be nested, templates can be used to build "components" and those components can be stored in separate files and compiled together at run time with a "model" being fed to the template(s) via a state object passed by the application.

So I may have a few dozen template files in a folder called /components, and another folder called /pages with a few templates that use these components. When a user visits a "page", the template file is "compiled" with the appropriate components.

A page might look like this:

  <html>
    {{template "nav"}}
    {{template "thread" .Thread}}
    {{template "footer"}}
  </html>
And "nav", "thread", and "footer" are all components defined in another file. This allows for re-use across multiple pages.

I want to do a write-up on it but I'm not sure if it's a novel idea.
telesoft
·4 yıl önce·discuss
>The main issue is that it doesn’t support placeholder values

Can you elaborate? Like give me an example of a route path that uses placeholder values? I use Go to build web apps too and I really don't see a need for anything other than the standard library.