June 20th, 2024

AdonisJS

AdonisJS is a TypeScript-first web framework for Node.js, emphasizing type-safety, intellisense, and performance. It offers testing support, official packages like Lucid for SQL ORM, Auth for authentication, and a vibrant community.

Read original articleLink Icon
AdonisJS

AdonisJS is a TypeScript-first web framework for Node.js, offering features like testing support, modern tooling, and an ecosystem of official packages. It allows for creating backend applications efficiently with features like type-safe environment variables, thoughtful folder structure, routing, controllers, middleware, encryption, and more. The framework emphasizes type-safety, seamless intellisense, and performance, with a single npm package providing core features to kickstart web application development without the need to assemble multiple packages. AdonisJS also excels in testing capabilities, including browser testing, API tests, and command-line tests. Additionally, it offers a variety of officially maintained packages like Lucid for SQL ORM, Auth for authentication, and FlyDrive for managing user-uploaded files. AdonisJS is praised by developers for its documentation, implementation, and similarity to Laravel, making it a popular choice for Node.js development. The framework is supported by a vibrant community and sponsors to sustain its development as an independent open-source project under the MIT license.

Related

AI-powered conversion from Enzyme to React Testing Library

AI-powered conversion from Enzyme to React Testing Library

Slack engineers transitioned from Enzyme to React Testing Library due to React 18 compatibility issues. They used AST transformations and LLMs for automated conversion, achieving an 80% success rate.

NodeSwift: Bridge Node.js and Swift

NodeSwift: Bridge Node.js and Swift

NodeSwift facilitates Swift and Node.js communication, leveraging macOS APIs, SwiftPM, NPM, and Swift for enhanced performance. It emphasizes safety, simplicity, and cross-platform compatibility, simplifying memory management and offering seamless integration.

Show HN: Eidos – Offline alternative to Notion

Show HN: Eidos – Offline alternative to Notion

The Eidos project on GitHub offers a personal data management framework as a Progressive Web App with AI features. Customizable with extensions and scripting, it leverages sqlite-wasm technology for chromium-based browsers.

Exposition of Front End Build Systems

Exposition of Front End Build Systems

Frontend build systems are crucial in web development, involving transpilation, bundling, and minification steps. Tools like Babel and Webpack optimize code for performance and developer experience. Various bundlers like Webpack, Rollup, Parcel, esbuild, and Turbopack are compared for features and performance.

My weekend project turned into a 3 years journey

My weekend project turned into a 3 years journey

Anthony's note-taking app journey spans 3 years, evolving from a secure Markdown tool to a complex Electron/React project with code execution capabilities. Facing challenges in store publishing, he prioritizes user feedback and simplicity, opting for a custom online deployment solution.

Link Icon 11 comments
By @Ciantic - 5 months
Looking at this, it has similar aspects as ASP.NET Core, and the same flaws as the Controller per class design used. Methods such as "index", "show" and "store" do not share a state, they shouldn't share a class either.

However, you can rectify this, by just not trying to share a class with any of those. In .NET Steve Smith, aka Ardalis shows how to do this with his Clean architecture [1]. One idea is to make a class for each endpoint. This also makes it easier for "Update" classes to share functionality with other "Update" classes and so on.

[1]: https://github.com/ardalis/CleanArchitecture/tree/main/sampl...

By @morbicer - 5 months
Nah, if you want heavy backend, go with Go/Ktor/C#, not node. If you want light backend, use sth like Hono or H3. If you want to primarily produce html, use Remix or Next.

Adonis/Redwood/Nest is something you will regret in few years because it will lock you down to "their" ways of doing things instead of something with replaceable components.

Admitted, Adonis looks most sensible out of these 3. Redwood is poisoned with needless GraphQL and Nest is written like 2008 java. In Adonis you can at least pick the db layer.

But even Adonis locks you to their validator instead of Zod or his cousins, they use their own Request/Response classes instead of the platform ones, has yucky inheritance and annotations magic etc.

By @Brosper - 5 months
I am just exploring this kind of frameworks for my company. I wonder how many people use it on productions and are happy with it.
By @begueradj - 5 months
I used it for 3 years where everything which was too important (a took a long time to be done by the only maintainer (Harminder Virk) at that time with his only one "helper" (Romain Lanz) , so long that I had to stop using it because it was difficult to use in those conditions.
By @madmaniak - 5 months
Hehey! I'm late for the party :D I just wanted people interested in frameworks to take a look on comparison with (my) framework which purposefully takes another approach https://news.ycombinator.com/item?id=40743058
By @holoduke - 5 months
I never understood why you need more than a simple expressjs server. After all nodejs works best if served directly after a load balancer. But before heavy duty application logic. Node is fast in accepting, forwarding and replying requests. Put your real work in small c# or golang apps.
By @jitl - 5 months
Has anyone tried both AdonisJS and RedwoodJS and can compare the two?

Adonis and Redwood are both trying to be the JavaScript version of Rails/Laravel - a traditional active-record based MVC rapid development server application framework.

The last time I looked for one of these (2018) they were immature and now at least in terms of website and documentation they both appear very capable. But if there’s one thing that JS libraries are good at, it’s marketing and slick documentation.

So, curious to hear any experiences with either and especially both.

Is it actually good?

By @nikodunk - 5 months
No mention of Views? The one thing I'd love to understand and is missing vs. Rails/Laraval is an integrated solution of solving the View part of MVC I think?

Looks like a really beautiful framework.

EDIT: Nevermind, it's in the docs, just not on the main landing page so feels a little more secondary. TLDR they recommend you use Edge/Pug/Nunjucks, htmx, vite for css bundling. Nice!

https://docs.adonisjs.com/guides/views-and-templates/introdu...

By @rpowers - 5 months
Anyone else see these types of announcement posts, and it's like they already have thousands of users? Where do y'all learn about these projects so early?
By @revskill - 5 months
Lack of vite/webpack/... FE integration is a huge breaker.