New codemods APIs, ace add command, and experimental assembler hooks
Changes
-
We now have a
node ace add
command which allows you to install and configure a package. In a single command, where before you would have had to donpm install ...
thennode ace configure ...
. This will be documented in more detail in the coming days. See adonisjs/v6-docs#44 -
The Codemods API now exposes the
getTsMorphProject
method, which retrieves an instance of tsmorph. This allows package authors to have direct access to ts-morph when they need to perform more specific modifications in the end-user code. Documentation https://docs.adonisjs.com/guides/scaffolding#gettsmorphproject -
The Codemods API also introduces two new methods:
registerVitePlugin
andregisterJapaPlugin
. See documentation here: https://docs.adonisjs.com/guides/scaffolding#registerviteplugin -
Added experimental assembler hooks. These hooks must be defined in the
adonisrc.ts
file and enable certain pieces of code to be executed at specific times during the build or dev server lifecycle. This feature will be useful for the new Vite integration we are experimenting :// adonisrc.ts export default defineConfig({ unstable_assembler: { onBuildStart: [ () => import('@my-package/hooks/build_start') ], onBuildEnd: [ () => import('@my-package/hooks/build_end') ], onSourceFileChanged: [ () => import('@my-package/hooks/source_file_changed') ], onDevServerStart: [ () => import('@my-package/hooks/dev_server_start') ], } })
Commits
- ci: use
main
as reference for test job ee4baba - test: fix test that fails when runned locally cf79688
- ci: remove test job
next
reference 295061f - chore: migrate to husky 9 1ca3b45
- chore: update dependencies fdd332e
- chore: update minimum node version e33b342
- feat: add getTsMorphProject method (#4414) ee96efe
- feat: add registerVitePlugin and registerJapaPlugin (#4412) db03e4c
- feat: do not run assets bundler when disabled in rc file (#4429) be6ca03
- chore: add extraneous package c0a86f3
- feat: add hooks for build and dev server (#4428) ca600ce
- style: lint file f01d683
- feat: add
node ace add
command (#4296) e7c668c - fix: description of --api and --resource flags d83e970
- fix(commands): swapped description in make:controller 8848191
What's Changed
- fix(commands): swapped description -a & -r for make:controller by @Blackwidow-sudo in #4420
- Add an
node ace add
command by @Julien-R44 in #4296 - feat: add hooks for build and dev server by @Julien-R44 in #4428
- feat: do not run assets bundler when explicitely disabled in rc file by @Julien-R44 in #4429
- feat: add registerVitePlugin and registerJapaPlugin by @Julien-R44 in #4412
- feat: add getTsMorphProject method by @Julien-R44 in #4414
New Contributors
- @Blackwidow-sudo made their first contribution in #4420
Full Changelog: v6.2.3...v6.3.0