I'm trying to load the Event system into an ace command.
public async run() {
const { default: Event } = await import('@ioc:Adonis/Core/Event')
}
However this results in the following error: Cannot resolve "Adonis/Core/Event" namespace from the IoC Container
Based on the documentation I'm doing this right: https://docs.adonisjs.com/guides/ace-commandline#top-level-imports-are-not-allowed
Could anyone please advise?