1.2.1 • Published 2 years ago

@d-dev/plop-add-files-plugin v1.2.1

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

Plop Add Files Plugin

A plugin for Plop. Similar to Plop's addMany action but allows for scaffolding some files without applying handlebars templating.

Usage

import addFiles from '@d-dev/plop-add-files-plugin'
export default async function (plop) {
  await addFiles(plop)

  plop.setGenerator('some-generator', {
    description: '',
    prompts: [],
    actions: [
      {
        type: 'addFiles',
        templateFiles: 'templates/some-template/**/*',
        destination: './{{name}}/',
        base: 'templates/some-template/',
      },
    ],
  })
}

Options

export type AddFilesOptions = {
  type: 'addFiles'
  templateFiles: string
  destination?: string
  base?: string
  verbose?: boolean
  force?: boolean
  skip?: boolean
  skipIfExists?: boolean
  globOptions?: glob.IOptions
  skipTemplating: (
    src: string,
    destination: string,
    answers: Record<string, unknown>,
    config: Record<string, unknown>,
  ) => boolean
}
1.2.0

2 years ago

1.2.1

2 years ago

1.1.0

2 years ago

1.0.5

2 years ago

1.0.4

2 years ago

1.0.3

2 years ago

1.0.2

2 years ago

1.0.1

2 years ago

1.0.0

2 years ago