-
-
Notifications
You must be signed in to change notification settings - Fork 88
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
help needed for build checking #269
Comments
+1 |
here is an example of how to use it |
It seems like using jiti with a higher version than in the example (1.21.0) will cause a webpack warning. Next config file // next.config.mjs
import createJiti from "jiti";
import { fileURLToPath } from "node:url";
const jiti = createJiti(fileURLToPath(import.meta.url));
// Import env here to validate during build. Using jiti we can import .ts files
jiti("./src/env/server");
jiti("./src/env/client"); Warning that is logged on both locale development and on Vercel. On locale development this is logged even on npm run dev, on Vercel this is during build.
Switching to the older jiti version (1.21.0) made the warning disappear. |
Is there a way to resolve this warning with the latest version of |
is there any more documentation/tutorials on how can i integrate unjs/jiti for checking env variables at build time with next.config.mjs?
The text was updated successfully, but these errors were encountered: