Use String replace instead of replaceAll for older versions of node.

This commit is contained in:
Dillon Kearns 2021-04-20 14:20:29 -07:00
parent ed58c97b4e
commit 14a103e6fb

View File

@ -10,7 +10,7 @@ async function run({ moduleName }) {
const content = fileContent(moduleName);
const fullFilePath = path.join(
`src/Template/`,
moduleName.replaceAll(".", "/") + ".elm"
moduleName.replace(/\./g, "/") + ".elm"
);
await fs.tryMkdir(path.dirname(fullFilePath));
fs.writeFile(fullFilePath, content);