Open craigharman opened 2 weeks ago
Can you explain your routes setup a bit more please?
If you can also send the output of noce ace list:routes --json
please
Sure. Rather than having a routes.ts
file I have a folder routes/
that contains routing files: app.ts
public.ts
etc.
Running the ace command I get Error: Cannot find module '/Users/.../start/routes.js'
That is because it doesn't exist! My routes are in /routes/
Try adding this code somewhere and give me the output please:
const router = await this.app.container.make('router')
router.commit()
console.log(router.toJSON())
Alternatively, try looking at this issue: https://github.com/Julien-R44/tuyau/issues/8 You may be facing the same problem.
And also if you can make a minimal reproduction, it would be ideal to be able to help you :)
I thought this may be related to having routes in a folder but I created a new project from scratch and moved the routes.ts
and the types are generated successfully so it doesn't appear to be that.
I reviewed #8 and can confirm I'm already using subpath imports.
Please provide a reproduction otherwise I can't help :/
I've just installed
tuyau
and tried to generate usingnode ace tuyau:generate
but I get the error:TypeError: routes is not iterable
. My routes are located in a folder in individual folder rather than in oneroutes.ts
file, wondering if that's the reason? Anything I can do to fix?