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
AFAIK currently the vite plugin doesn't allow to declare a custom middleware and so managing the telefunc context. This is really pain full as it prevent us from using it as soon as authenticated calls are required on the API.
The automatically injected middleware you're referring to isn't really supposed to be used by end-users. (It's only used for creating minimal /examples/.) Admittedly it's confusing and it's something the docs and examples should clarify (it's on the radar).
I guess we can close this, but let me know if you still have questions.
(Btw. in case your company is up for it, we're looking for sponsors.)
AFAIK currently the vite plugin doesn't allow to declare a custom middleware and so managing the telefunc context. This is really pain full as it prevent us from using it as soon as authenticated calls are required on the API.
telefunc/telefunc/node/vite/plugins/devConfig.ts
Lines 31 to 41 in a97e22f
telefunc/telefunc/node/vite/helpers/addTelefuncMiddleware.ts
Lines 7 to 37 in a97e22f
It would be great to be able to pass a plugin option to register custom behaviour like:
ℹ️ Note that the same behaviour is applied to the preview command here: https://github.com/brillout/telefunc/blob/main/telefunc/node/vite/plugins/previewConfig.ts#L22
The text was updated successfully, but these errors were encountered: