HNHacker News
TopNewBestAskShowJobs

vsroy

191 karma · joined October 8, 2019

submissionscomments
vsroy··on Facebook open sources Lexical, an extensible text editor library
Another follow-up question: Do you think Lexical would be a good fit for a "live preview" type editor?

Live preview = the editor is WYSIWYG but the storage format is Markdow

Example: https://help.obsidian.md/Live+preview+update

vsroy··on Facebook open sources Lexical, an extensible text editor library
When you say inline markdown shortcut, is an example of that pressing Ctrl-B on some highlighted text in order to surround it with asterisks?

And is the idea of mentions that we can use Lexical to provide nice things like pop-up auto-complete of a username / automatically transform the username into a link inside of the input text?

vsroy··on Facebook open sources Lexical, an extensible text editor library
Let's say I'm building a stack overflow style editor (you type markdown and it gets rendered in a preview tab) -- would there be any reason to use lexical?
vsroy··on Murri: Infinite responsive, sortable, filterable and draggable layouts
What is the use case for this? Is it for making advanced layouts that HTML + CSS can't handle?
vsroy··on Ask HN: How to make server side code atomic?
> Also, hopefully the API you use to send email has a way to avoid duplicate emails, perhaps by attaching a unique ID to the request that's used to detect duplicate sends.

I think this is the interesting part. Storing a value in the table to be processed by a queue seems normal / not rocket science. But what happens when we 1. Call the API 2. The API succeeds 3. We crash before we can write success

Now we'll send duplicate emails. I don't think all APIs have ways to avoid duplicate emails/transactions, so that could be a hairy problem.

vsroy··on Ask HN: How to make server side code atomic?
I'll take another look. I skimmed the article to get an understanding of idempotency keys without reading it in full detail.
vsroy··on Ask HN: How to make server side code atomic?
Thanks! This was a good article. I guess there's a question of what to do if the API does not have idem-potency keys, (maybe it's possible to wrap it?)
vsroy··on Ask HN: How to make server side code atomic?
There's one hole here where it feels like things could slip through. - You call the send email API but your server crashes before the API returns 200.

This would be fine in the case of email servers (you just end up sending the email twice). It seems a lot less fine in the case of Stripe transactions.

I guess, the concept of idem-potency keys can solve this issue. (https://brandur.org/idempotency-keys)

vsroy··on Ask HN: How to make server side code atomic?
I see a few solutions in the comments: but one thing that is not acknowledged is: "What do you do if the email service executes successfully but your server crashes before the POST is returned". I guess this isn't the worst thing in the world since that just means you send the email twice.

Edit: Actually the worst case is pretty bad, you could accidentally double-charge a user using Stripe.

vsroy··on Accidentally making a language, for an engine, for a game
What are some of the interesting tradeoffs this language has made? Ideally with super small code samples
vsroy··on Nushell 0.60 Released
Can anyone who has used nushell for a while comment on pros/cons?
vsroy··on Networking of a turn-based game
Could ZKPs help here?
vsroy··on Transformer Memory as a Differentiable Search Index
Can someone provide a layman's explanation?
vsroy··on Making JavaScript run fast on WebAssembly
I think the fact that you can save WASM memory / state will yield itself for very powerful applications in the future.

I think there's a world where true time-travel debugging is possible because you execute your Python program inside of a WASM VM & with WASM, you can save the memory/local registers/etc. and do true backwards/forwards execution.

vsroy··on Overwork contributes to 745k premature deaths per year
Can someone explain why overwork kills people? I'm curious, maybe there's a way to work 70 hour weeks without harming your health? (I.e possibly overwork is correlated with lack of sleep / exercise, which are the real dangers, not the work itself).
vsroy··on GitHub isn't fun anymore
I see a lot of disagreement with this post but I think it makes good points.

It's hard for small developers who make useful things to get noticed on GitHub. The only hope is to get retweeted by some established user. This seems silly, we need better ways of making sure people can find/discover good software.

vsroy··on Show HN: Compiletime macro to auto generate fast validators for TypeScript types
Yes, it must be placed in the same file as the type itself.

Side note: It is a Babel macro :)

← PreviousPage 2 of 2