Skip to content

Open source website builder and Webflow alternative. Webstudio is an advanced visual builder that connects to any headless CMS, supports all CSS properties, and can be hosted anywhere, including with us.

add note about imports to template

Roman Pominoveed991b7fec1
diff --git a/packages/prisma-client/prisma/migrations/template.txt b/packages/prisma-client/prisma/migrations/template.txt
index b619457af1..7ca8fddd80 100644
--- a/packages/prisma-client/prisma/migrations/template.txt
+++ b/packages/prisma-client/prisma/migrations/template.txt
@@ -1,5 +1,18 @@
import { PrismaClient } from "./client";
+// NOTE ON IMPORTS:
+//
+// You shouldn't import any code that can change as the project evolves!
+//
+// It should be safe to import a library like `uuid` as its API is unlikely to change.
+// For application code, it's better to copy it to the migration directory.
+//
+// If you have to import something that may change,
+// be prepared to keep the migration code up to date as well.
+//
+// This is necessary because we want to be able to run old migrations at any point.
+// For example, when we setting up a fresh database or making a reset.
+
export default () => {
const client = new PrismaClient();
return client.$transaction(async (prisma) => {