mirror of
https://github.com/hanzoai/next.js.git
synced 2026-09-24 17:00:51 +00:00
### What? Use [Turborepo generators](https://turbo.build/repo/docs/core-concepts/monorepos/code-generation#custom-generators) instead of plop. Turborepo generators are built on top of plop, but include some additional tooling to make working in monorepos easier. It also supports zero config typescript for configs. ### Why? Same Team! ### How? Ported the existing plopfile to a turbo generator config Co-authored-by: Jiachi Liu <[email protected]>
10 lines
230 B
TypeScript
10 lines
230 B
TypeScript
import type { NodePlopAPI } from 'node-plop'
|
|
|
|
export function toFileName(str: string) {
|
|
return str.toLowerCase().replace(/ /g, '-')
|
|
}
|
|
|
|
export function init(plop: NodePlopAPI): void {
|
|
plop.setHelper('toFileName', toFileName)
|
|
}
|