Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Skip props request for static routes #34

Open
frandiox opened this issue Jun 13, 2021 · 0 comments
Open

Skip props request for static routes #34

frandiox opened this issue Jun 13, 2021 · 0 comments

Comments

@frandiox
Copy link
Owner

frandiox commented Jun 13, 2021

Right now, a props handler file needs to export a handler function. It should be possible to omit this handler and only export cache options. In this scenario, the route can skip the props request in SPA mode while still having access to cache options.

Alternatives:

  • Keep functions/props/routeName.js naming and check the content to see whether handler funciton is exported or not.
  • Use functions/props/routeName.static.js naming.
  • Use functions/props/routeName.json naming. -- It seems nice but it wouldn't have type auto completion.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant