A small follow-up, on this page I saw that “lifecycles.ts” should be in src > api > demo > content-types > demo
. When I move the file over here I do see “test” in the console. So problem resolved you’d think… But, Strapi being Strapi, this change comes with its own problem. Since when I move the file over here, the event.params.context.state object is empty.
It most surely has to do with the flow of the request. Is the lifecycles.ts file in the (...)/content-types/demo
directory applied on the route policy? route middleware? or global middleware? Can someone point me to this in the documentation? And still… How does that influence the display of the console.log