github adonisjs/core v6.3.0
New codemods APIs, ace add command, and experimental assembler hooks

latest releases: v6.12.1, v6.12.0, v6.11.0...
4 months ago

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 do npm install ... then node 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 and registerJapaPlugin. 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

New Contributors

Full Changelog: v6.2.3...v6.3.0

Don't miss a new core release

NewReleases is sending notifications on new releases.