You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Oct 3, 2023. It is now read-only.
Currently, Dyson only loads routes from files with extension
.js
.I'd like to express my route files as
.ts
, in TypeScript.However, those files are not loaded.
I've traced to
loader.js:8
where it callsconst rawConfigs = requireDir(module, path.resolve(configDir));
requireDir
itself accepts an optional third parameter which is an object that allows defining which extensions to look for.Changing it to
const rawConfigs = requireDir(module, path.resolve(configDir), {extensions: ['js','ts']});
Seems to have done the trick.
Is this something that could be somehow added to Dyson?
The text was updated successfully, but these errors were encountered: