Skip to content

Commit

Permalink
feat: Move plop templates files
Browse files Browse the repository at this point in the history
  • Loading branch information
SkrzypMajster committed Sep 11, 2023
1 parent 127773a commit 79a65ef
Show file tree
Hide file tree
Showing 31 changed files with 28 additions and 28 deletions.
6 changes: 3 additions & 3 deletions plop/generators/apiActions.generator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,17 +16,17 @@ export const apiActionsGenerator: PlopGeneratorConfig = {
{
type: 'add',
path: 'src/api/actions/{{camelCase name}}/{{camelCase name}}.mutations.ts',
templateFile: 'plop-templates/apiActions/apiActions.mutations.hbs',
templateFile: 'plop/templates/apiActions/apiActions.mutations.hbs',
},
{
type: 'add',
path: 'src/api/actions/{{camelCase name}}/{{camelCase name}}.queries.ts',
templateFile: 'plop-templates/apiActions/apiActions.queries.hbs',
templateFile: 'plop/templates/apiActions/apiActions.queries.hbs',
},
{
type: 'add',
path: 'src/api/actions/{{camelCase name}}/{{camelCase name}}.types.ts',
templateFile: 'plop-templates/apiActions/apiActions.types.hbs',
templateFile: 'plop/templates/apiActions/apiActions.types.hbs',
},
{
type: 'modify',
Expand Down
4 changes: 2 additions & 2 deletions plop/generators/apiMutation.generator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ export const apiMutationGenerator = (toKebabCase: Function): PlopGeneratorConfig
type: 'modify',
path: 'src/api/actions/{{collection}}/{{collection}}.types.ts',
pattern: getPlaceholderPattern('API_ACTION_TYPES'),
templateFile: 'plop-templates/apiMutation/apiMutation.types.hbs',
templateFile: 'plop/templates/apiMutation/apiMutation.types.hbs',
},
{
type: 'modify',
Expand All @@ -54,7 +54,7 @@ export const apiMutationGenerator = (toKebabCase: Function): PlopGeneratorConfig
type: 'modify',
path: 'src/api/actions/{{collection}}/{{collection}}.mutations.ts',
pattern: getPlaceholderPattern('MUTATION_FUNCTIONS_SETUP'),
templateFile: 'plop-templates/apiMutation/apiMutation.hbs',
templateFile: 'plop/templates/apiMutation/apiMutation.hbs',
}
],
});
4 changes: 2 additions & 2 deletions plop/generators/apiQuery.generator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ export const apiQueryGenerator = (toKebabCase: Function): PlopGeneratorConfig =>
type: 'modify',
path: 'src/api/actions/{{collection}}/{{collection}}.types.ts',
pattern: getPlaceholderPattern('API_ACTION_TYPES'),
templateFile: 'plop-templates/apiQuery/apiQuery.types.hbs',
templateFile: 'plop/templates/apiQuery/apiQuery.types.hbs',
},
{
type: 'modify',
Expand All @@ -42,7 +42,7 @@ export const apiQueryGenerator = (toKebabCase: Function): PlopGeneratorConfig =>
type: 'modify',
path: 'src/api/actions/{{collection}}/{{collection}}.queries.ts',
pattern: getPlaceholderPattern('QUERY_FUNCTIONS_SETUP'),
templateFile: 'plop-templates/apiQuery/apiQuery.hbs',
templateFile: 'plop/templates/apiQuery/apiQuery.hbs',
}
],
});
6 changes: 3 additions & 3 deletions plop/generators/appComponent.generator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,17 +21,17 @@ export const appComponentGenerator: PlopGeneratorConfig = {
{
type: 'add',
path: `src/app/{{directory}}/{{camelCase name}}/{{pascalCase name}}.tsx`,
templateFile: 'plop-templates/component/Component.hbs',
templateFile: 'plop/templates/component/Component.hbs',
},
{
type: 'add',
path: `src/app/{{directory}}/{{camelCase name}}/{{pascalCase name}}.test.tsx`,
templateFile: 'plop-templates/component/Component.test.hbs',
templateFile: 'plop/templates/component/Component.test.hbs',
},
{
type: 'add',
path: `src/app/{{directory}}/{{camelCase name}}/{{pascalCase name}}.types.ts`,
templateFile: 'plop-templates/component/Component.types.hbs',
templateFile: 'plop/templates/component/Component.types.hbs',
},
],
};
8 changes: 4 additions & 4 deletions plop/generators/appContainerComponent.generator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,22 +21,22 @@ export const appContainerComponentGenerator: PlopGeneratorConfig = {
{
type: 'add',
path: `src/app/{{directory}}/{{camelCase name}}/{{pascalCase name}}.tsx`,
templateFile: 'plop-templates/component/Component.hbs',
templateFile: 'plop/templates/component/Component.hbs',
},
{
type: 'add',
path: `src/app/{{directory}}/{{camelCase name}}/{{pascalCase name}}.test.tsx`,
templateFile: 'plop-templates/component/Component.test.hbs',
templateFile: 'plop/templates/component/Component.test.hbs',
},
{
type: 'add',
path: `src/app/{{directory}}/{{camelCase name}}/{{pascalCase name}}Container.tsx`,
templateFile: 'plop-templates/component/Container.hbs',
templateFile: 'plop/templates/component/Container.hbs',
},
{
type: 'add',
path: `src/app/{{directory}}/{{camelCase name}}/{{pascalCase name}}.types.ts`,
templateFile: 'plop-templates/component/ContainerComponent.types.hbs',
templateFile: 'plop/templates/component/ContainerComponent.types.hbs',
},
],
};
14 changes: 7 additions & 7 deletions plop/generators/context.generator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,37 +15,37 @@ export const contextGenerator: PlopGeneratorConfig = {
{
type: 'add',
path: 'src/context/{{camelCase name}}/{{camelCase name}}Context/{{pascalCase name}}Context.ts',
templateFile: 'plop-templates/context/Context.hbs',
templateFile: 'plop/templates/context/Context.hbs',
},
{
type: 'add',
path: 'src/context/{{camelCase name}}/{{camelCase name}}Context/{{pascalCase name}}Context.types.ts',
templateFile: 'plop-templates/context/Context.types.hbs',
templateFile: 'plop/templates/context/Context.types.hbs',
},
{
type: 'add',
path: 'src/context/{{camelCase name}}/{{camelCase name}}Context/{{pascalCase name}}Context.test.tsx',
templateFile: 'plop-templates/context/Context.test.hbs',
templateFile: 'plop/templates/context/Context.test.hbs',
},
{
type: 'add',
path: 'src/context/{{camelCase name}}/{{camelCase name}}ContextController/{{pascalCase name}}ContextController.tsx',
templateFile: 'plop-templates/context/ContextController.hbs',
templateFile: 'plop/templates/context/ContextController.hbs',
},
{
type: 'add',
path: 'src/context/{{camelCase name}}/{{camelCase name}}ContextController/{{pascalCase name}}ContextController.types.ts',
templateFile: 'plop-templates/context/ContextController.types.hbs',
templateFile: 'plop/templates/context/ContextController.types.hbs',
},
{
type: 'add',
path: 'src/hooks/use{{pascalCase name}}/use{{pascalCase name}}.ts',
templateFile: 'plop-templates/context/useContext.hbs',
templateFile: 'plop/templates/context/useContext.hbs',
},
{
type: 'add',
path: 'src/hooks/use{{pascalCase name}}/use{{pascalCase name}}.test.tsx',
templateFile: 'plop-templates/context/useContext.test.hbs',
templateFile: 'plop/templates/context/useContext.test.hbs',
},
],
};
6 changes: 3 additions & 3 deletions plop/generators/customHook.generator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,18 +15,18 @@ export const customHookGenerator: PlopGeneratorConfig = {
{
type: 'add',
path: 'src/hooks/{{camelCase name}}/{{camelCase name}}.tsx',
templateFile: 'plop-templates/hook/hook.hbs',
templateFile: 'plop/templates/hook/hook.hbs',
},
{
type: 'add',
path: 'src/hooks/{{camelCase name}}/{{camelCase name}}.test.tsx',
templateFile: 'plop-templates/hook/hook.test.hbs',
templateFile: 'plop/templates/hook/hook.test.hbs',
},
{
type: 'modify',
path: 'src/hooks/index.ts',
pattern: 'export',
templateFile: 'plop-templates/hook/hook.index.hbs',
templateFile: 'plop/templates/hook/hook.index.hbs',
},
],
};
8 changes: 4 additions & 4 deletions plop/generators/uiComponent.generator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,23 +15,23 @@ export const uiComponentGenerator: PlopGeneratorConfig = {
{
type: 'add',
path: `src/ui/{{camelCase name}}/{{pascalCase name}}.tsx`,
templateFile: 'plop-templates/component/Component.hbs',
templateFile: 'plop/templates/component/Component.hbs',
},
{
type: 'add',
path: `src/ui/{{camelCase name}}/{{pascalCase name}}.test.tsx`,
templateFile: 'plop-templates/component/Component.test.hbs',
templateFile: 'plop/templates/component/Component.test.hbs',
},
{
type: 'add',
path: `src/ui/{{camelCase name}}/{{pascalCase name}}.types.ts`,
templateFile: 'plop-templates/component/Component.types.hbs',
templateFile: 'plop/templates/component/Component.types.hbs',
},
{
type: 'modify',
path: 'src/ui/index.ts',
pattern: 'export',
templateFile: 'plop-templates/component/Component.index.hbs',
templateFile: 'plop/templates/component/Component.index.hbs',
},
]
};
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit 79a65ef

Please sign in to comment.