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

docs: allow Zod to be used in dev tools at site #2432

Merged
merged 1 commit into from May 21, 2023

Conversation

jrel
Copy link
Contributor

@jrel jrel commented May 15, 2023

This change allows us to test Zod on the documentation site for a simple playground test!

@netlify
Copy link

netlify bot commented May 15, 2023

Deploy Preview for guileless-rolypoly-866f8a ready!

Built without sensitive environment variables

Name Link
🔨 Latest commit dea4e90
🔍 Latest deploy log https://app.netlify.com/sites/guileless-rolypoly-866f8a/deploys/6464e681605b6400085e6e9c
😎 Deploy Preview https://deploy-preview-2432--guileless-rolypoly-866f8a.netlify.app/
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

index.html Outdated
@@ -256,5 +256,6 @@
.prepend(document.querySelector(".theme-btn"));
});
</script>
<script src="https://www.unpkg.com/zod@3.21.4/lib/index.umd.js"></script>
Copy link
Contributor

@samchungy samchungy May 17, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You'd probably want that version to be the latest so removing the 3.21.4 would make more sense

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You are sure. I will change!

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

After reading the post about how the docs site works here, I think we can use the built lib instead of the published lib. This allows us to test the PR changes on the Deploy Preview site.

The current problem with doing this is that the build stage runs on the GitHub action, and Netlify loads the resources directly from GitHub.
To fix this, we need to configure the build command in Netlify and use /index.umd.js as src!

Does it make sense to make this kind of change?

@colinhacks
Copy link
Owner

Great idea

@colinhacks colinhacks merged commit 67f35b1 into colinhacks:master May 21, 2023
5 checks passed
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

Successfully merging this pull request may close these issues.

None yet

3 participants