diff --git a/src/create.js b/src/create.js index cb89315..f5afbcb 100755 --- a/src/create.js +++ b/src/create.js @@ -3,13 +3,13 @@ /* eslint-disable no-console */ import prompts from 'prompts'; import { run as setupDefaultContent } from './generators/default-content/index.js'; +import { run as setupD2ldev } from './generators/d2ldev/index.js'; import { run as setupDemo } from './generators/demo/index.js'; import { run as setupElement } from './generators/wc-lit-element/index.js'; import { run as setupLocalization } from './generators/localization/index.js'; import { run as setupRelease } from './generators/release/index.js'; import { run as setupTestUnit } from './generators/test-unit/index.js'; import { run as setupTestVdiff } from './generators/test-vdiff/index.js'; -import { run as setupD2ldev } from './generators/d2ldev/index.js'; const generatorTypes = { component: 'component', diff --git a/src/generators/d2ldev/index.js b/src/generators/d2ldev/index.js index f5fa959..78643ec 100644 --- a/src/generators/d2ldev/index.js +++ b/src/generators/d2ldev/index.js @@ -1,5 +1,10 @@ +import { + copyAndProcessDir, + getDestinationPath, + movePlugin, + replaceTextPlugin +} from '../../helper.js'; import path from 'path'; -import { copyAndProcessDir, getDestinationPath, replaceTextPlugin, movePlugin } from '../../helper.js'; export function run(templateData) { const templateRoot = path.join(__dirname, 'templates'); diff --git a/src/helper.js b/src/helper.js index d9cbc36..65a2bd7 100644 --- a/src/helper.js +++ b/src/helper.js @@ -167,7 +167,7 @@ export function replaceTextPlugin(perFileReplacements = {}) { const { relativePath, fileName } = context; const replacements = normalizedPerFileReplacements[path.join(relativePath, fileName)]; if (replacements) { - replaceText(destination, replacements) + replaceText(destination, replacements); } } };