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

Correctly parse and implement netlify.toml #1

Closed
9 of 11 tasks
8eecf0d2 opened this issue Oct 15, 2018 · 3 comments
Closed
9 of 11 tasks

Correctly parse and implement netlify.toml #1

8eecf0d2 opened this issue Oct 15, 2018 · 3 comments
Labels
backburner enhancement New feature or request help wanted Extra attention is needed

Comments

@8eecf0d2
Copy link
Owner

8eecf0d2 commented Oct 15, 2018

Netlify doesn't clearly specify required properties for toml configs and testing what happens within different scenarios is a pain so for the purpose of simplifying things I think it's best to enforce explicit with toml configurations, for example an error will be thrown if the static router is being initialised but there is no build.publish property specified.

Context

  • Derive context from current git branch.
  • Add a -c --context option to override.
  • Inject environment variables if any.
  • Support base prop.

Redirects

  • Support from, to prop.
  • Support status prop.
  • Support force prop (could be tricky).
  • Support query prop (could be tricky).
  • Support conditions prop (could be really tricky).
  • Support headers prop.

Headers

  • General support for setting headers based on for prop.
@8eecf0d2 8eecf0d2 changed the title Correctly parse and implement netlify.toml Correctly parse and implement netlify.toml Oct 15, 2018
@8eecf0d2 8eecf0d2 added enhancement New feature or request help wanted Extra attention is needed labels Oct 15, 2018
@8eecf0d2 8eecf0d2 self-assigned this Oct 15, 2018
@8eecf0d2
Copy link
Owner Author

8eecf0d2 commented Oct 15, 2018

Ps. I don't use headers or redirects props which aren't currently implemented, so this is already on the back burner...

@8eecf0d2
Copy link
Owner Author

8eecf0d2 commented Oct 17, 2018

Turns out Netlify redirects aren't actual redirects 🤦‍♀️ but rather routing rules for the static server so 0dcaeaa was actually semi correct... will try and implement a clean solution using serve-static, adding support for glob patterns will be a challenge.

Not sure how I missed it, just finished reading Netlify's Redirect Docs and it's not looking good for redirects support... this is going to be a major feature to implement, I'll try and break it down as logically as possible and provide a checklist in another issue. 🙈

@8eecf0d2
Copy link
Owner Author

Closing in favour of #8

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backburner enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

1 participant