Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
unemployable
searching Neon…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
6 ms
·
1.
▲
Flyweight: A Node.js ORM Specifically for SQLite
(github.com)
94 points
by
unemployable
2y ago
|
43 comments
2.
▲
by
unemployable
2y ago
Memory leaks can occur when a component adds events to an element outside of the component (such as the window) and then gets removed from the DOM without removing the event handler from the window. This is solved in native Web Components b
3.
▲
by
unemployable
2y ago
>If you want to get deeper into it, have a look at event bubbling and propagation. In this example, the event is on the Window. There is no bubbling. It is already at the top level. >Believe me, you don’t want to use the standard even
4.
▲
Show HN: Quietone – search audio and video by transcript
(andrewitsover.com)
1 points
by
unemployable
2y ago
|
0 comments
5.
▲
by
unemployable
4y ago
Exactly. All I care about is getting things done quickly and moving on. At university I was taught about "maintainable code", but in real life, I have never seen such code. I have inherited code written by teams and it was not goo
6.
▲
Comparing React to VanillaJS
(itsover.au)
2 points
by
unemployable
4y ago
|
1 comments
7.
▲
by
unemployable
4y ago
I found React to be the worst framework I have ever used. There is no chain of functions to debug or follow. Changing the state sets off a chain reaction of chaos that spreads throughout the codebase that can never be traced back to its ori
8.
▲
by
unemployable
4y ago
Why do you think it is more complicated? The logic of the UI and application itself is the complicated part. That is the difference between a document and an application. The HTML ends up being turned into small pieces and has to be dynamic
9.
▲
Artwork – a simple front-end framework with no HTML
(github.com)
1 points
by
unemployable
4y ago
|
4 comments
10.
▲
by
unemployable
4y ago
Applications do not really benefit from markup language. Artwork uses only JavaScript and CSS, and uses web components to enable scoped CSS and so on. It avoids classes as they are too much ceremony. Projects using Artwork can be run withou
11.
▲
by
unemployable
4y ago
There is also Cloudflare D1, which is now in public alpha.
12.
▲
by
unemployable
4y ago
>I think this is something that pgsql got quite right I don't think so. For example, pgsql had an array type before it got JSON, so the drivers can't automatically convert arrays that you want to insert into JSON. With my SQLit
13.
▲
by
unemployable
4y ago
>If there are many client programs sending SQL to the same database over a network I believe this is a reference to enterprises that have different users querying the database directly with SQL that they wrote over a network to a central
14.
▲
by
unemployable
4y ago
When you want to update the types, you have to run something to update the one file that contains the types (or put it in watch mode to do it automatically). You don't necessarily have to update the types straight away though as I use
15.
▲
by
unemployable
4y ago
>Every ORM that I've worked with is a separate DSL that I need to learn That is the point of Flyweight. The API is very small, and for everything else you use SQL. The ORM parses the SQL to figure out the types, and when you want it
16.
▲
by
unemployable
4y ago
In an ORM, you will write include: ['posts'] in SQL, you will write join posts on p.authorId = a.id I would argue an ORM is more about getting the flat structure of the result set into an hierarchical set of objects
17.
▲
by
unemployable
4y ago
You are missing the steps to get that select statement into JavaScript (running the database command, passing in the parameters, parsing the result, etc).
18.
▲
Flyweight: An ORM for SQLite
(github.com)
90 points
by
unemployable
4y ago
|
103 comments
19.
▲
by
unemployable
4y ago
Flyweight parses SQL statements to generate a TypeScript API, uses convention to automatically map SQL into hierarchical data structures, and combines this with a simple CRUD API.
20.
▲
by
unemployable
4y ago
Everything in this article is true. As you can see by the comments in this thread, saying "I love TypeScript" is not enough to please the TypeScript cult. Nothing but complete devotion is required. You can say "it has its fla
21.
▲
by
unemployable
4y ago
Yeah that is the main problem with not using soft deletes. The question is though, if you delete a user, should the user's personal information still exist in your database, or does that violate some kind of privacy regulations? The id
22.
▲
by
unemployable
4y ago
Everybody always did soft deletes with the is_deleted column at companies I once worked for so that is what I would do. I noticed that a lot of bugs would occur this way because you would forget to add the is_deleted to the query somewhere.