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

Document minimum typescript version #351

Closed
johanndev opened this issue Jan 4, 2024 · 7 comments
Closed

Document minimum typescript version #351

johanndev opened this issue Jan 4, 2024 · 7 comments
Assignees
Labels
documentation Improvements or additions to documentation

Comments

@johanndev
Copy link

Hi!

The documentation is missing a note about the minimum typescript version that is required for valibot to work (5.0.2?)
This should probably be documented on the installation page.

If you could confirm the minimal typescript version, I can provide a PR for the website - thanks!

@fabian-hiller
Copy link
Owner

Do you know if there is a way to figure out the minimum TypeScript version required? I think the most advanced feature we are using ist the const modifier that was shipped with v5.

@fabian-hiller fabian-hiller self-assigned this Jan 5, 2024
@fabian-hiller fabian-hiller added the documentation Improvements or additions to documentation label Jan 5, 2024
@johanndev
Copy link
Author

johanndev commented Jan 5, 2024

I'm not aware of a programmatic way of determining the required TS version - I found 5.0.2 as the min version just by trial and error.
EDIT: One idea would be to introduce an integration test that sets up a minimal project and checks if there are build/type errors.

@fabian-hiller
Copy link
Owner

We could add the following to the "General" section of the installation guide below the tsconfig.json text.

The minimum required TypeScript version is v5.0.2.

If you are interested, feel free to create a draft PR for an integration test.

@johanndev
Copy link
Author

We could add the following to the "General" section of the installation guide below the tsconfig.json text.

Yes, that sounds perfect 👍

If you are interested, feel free to create a draft PR for an integration test.

I'm gonna do some research first, I'll get back to you :)

@fabian-hiller
Copy link
Owner

I added the min version info to the docs.

@johanndev
Copy link
Author

I created a draft PR: #354

As the original issue was addressed, I'm gonna close this discussion.

@fabian-hiller
Copy link
Owner

Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

No branches or pull requests

2 participants