101010.pl is one of the many independent Mastodon servers you can use to participate in the fediverse.
101010.pl czyli najstarszy polski serwer Mastodon. Posiadamy wpisy do 2048 znaków.

Server stats:

484
active users

#LibResilient

0 posts0 participants0 posts today

Rewriting #LibResilient tests in #Deno and… damn!

The number of random "add a timeout to wait here and hope all random promises started deep in the code resolve before it" I am removing — partially because I now understand my code better, partially because Deno has sane, reliable implementations of WebAPIs — is quite substantial.

Makes me a happy camper.

Rewriting #LibResilient's tests in #Deno (from NodeJS and Jest) not only helps me write cleaner code and get rid of the mess that npm dependencies are, but also it helps me understand #JavaScript better, it seems.

In a number of places (in tests and in code they test) it forced me to actually *understand* some quirk of the language and re-write stuff in a cleaner, more unambiguous, easier to debug way.

Can't wait for the rewrite to be done so that I can remove the last bits of npm crap!

#LibResilient documentation is now more usable
resilient.is/blog/better-expos

It took me a good while but finally LibResilient's documentation (including that of its plugins) is available in one place:
resilient.is/docs/

🎉

There's an index, the whole thing is nicely browseable, and it's all a nice static site, because of course it is. :blobcatcoffee:

I'm hoping this will make it easier for people to engage with the project and maybe deploy it on their websites. 🤞

resilient.isDocumentation is now more usable | resilient.is

#LibResilient got a CLI
resilient.is/blog/libresilient

It's a tricky beast to implement, mainly because most relevant functionality comes from plugins anyway, so the CLI necessarily also has to basically be a thin layer over the plugin code.

The nice thing is that it's implemented in @deno_land. Compared to NodeJS, the difference is like night and day. Deno has a built-in test system, and implements all the WebAPIs LibResilient uses natively.

Might have to re-write all my Jest tests in Deno! 🤔

resilient.isLibResilient CLI | resilient.is

New in #LibResilient — two #DNSLink based transport plugins:
resilient.is/blog/new-dnslink-

DNSLink makes a lot of sense in LibResilient: DNS is often more reliable than web, and DNSLink offers a way to make certain information — here: where to fetch content from — available in case the main site is down without having to put that in the configuration.

This means more flexibility in case main site is down. Easier to push out updates related to alternative endpoints or current IPFS CID.

resilient.isNew DNSLink-based transport plugins | resilient.is

Writing tests in #Deno :dinosaur: is positively *pleasant*.

No clue how they achieved that, but compared with Jest, and especially if you're testing stuff that relies on WebAPIs, Deno is a clear improvement.

Much recommend:
deno.land/manual@v1.28.3/basic

Looks like I might be able to tear all the NodeJS/npm crap from #LibResilient after all. Fantastic. 🎉

DenoTesting | Manual | DenoDeno has a built-in test runner that you can use for testing JavaScript or TypeScript code.