We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 78b813d commit 3ff5247Copy full SHA for 3ff5247
src/templates-worker.ts
@@ -74,21 +74,21 @@ export class TemplatesWorker {
74
);
75
};
76
77
- requireFnFromTemplate = async (packageOrPath: string) => {
+ requireFnFromTemplate = (packageOrPath: string) => {
78
const isPath =
79
packageOrPath.startsWith("./") || packageOrPath.startsWith("../");
80
81
if (isPath) {
82
- return await import(
+ return require(
83
path.resolve(
84
this.config.templatePaths.custom ||
85
this.config.templatePaths.original,
86
packageOrPath,
87
- )
+ ),
88
89
}
90
91
- return await import(packageOrPath);
+ return require(packageOrPath);
92
93
94
getTemplate = (name: string, fileName: string, path?: string) => {
0 commit comments