What a difference between Adonisjs 4.1 and adonisjs 5

I have create a project with Adonisjs V4.1 and is finished, now I want to know the difference between both versions, and I can Update my project from 4.1 to 5?

The differences are not clear to everyone in the community - but of course, we will get to know more about v5 in a couple of weeks.

Note that this is a preview version.


I’ll my own answer from Discord:

I’ve been hacking around with V5 for quite some time (bundled it somehow together from Github repos)
And v4 docs helped a lot to glue all the componentes together and figure out how everything works
Most of the stuff is same, didn’t notice any changes (maybe some variable name changes etc)

Biggest changes IMO are configuration changes, need to copy-paste config to some other files.
There were some slight differences in Indicative (validator) if I remember correctly.
But I think migrating quite big scale project shouldn’t take more than one evening for one developer

Node: I haven’t used Lucid in v5, since I wrote my own DB provider (RethinkDB). When v5 finally lands I’ll make RethinkDB provider work better with Lucid, like Lucid-mongo works currently

1 Like

Hi all, :wave:

The biggest change is the new TypeScript codebase, you will need to change all of your file to TypeScript. Also, there’s a complete new IoC Container and a new DI system.

@prashanth1k, it’s a “preview version” but already used in production on multiples applications. :smile:


@romain.lanz Do you really need to? Or it’s needed for preview version only?

Since you could eventually just change all .js files to .ts and it would be legit TS (might have to make linter less strict tho)

1 Like

Even doing so could not be enough. As said, core features like IoC & DI have changed, so you will need to refactor your code.


Is there an available open source code base of these Adonis v5 in production?

Didn’t plan to open-source it yet since code is still pile of cheese. But here is one: https://gitlab.com/star-conflict/site/sc-api

1 Like