Skip to content

Commit 897cad5

Browse files
committed
chore: adjust type imports
1 parent eb45665 commit 897cad5

9 files changed

Lines changed: 12 additions & 13 deletions

File tree

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,8 @@
3232
"lint:check:types": "tsc --noEmit",
3333
"lint:check:js": "eslint .",
3434
"lint:fix:js": "eslint . --fix",
35-
"lint:check:format": "prettier . --check",
36-
"lint:fix:format": "prettier . --write",
35+
"lint:check:format": "prettier \"**/*.{json,yaml,md}\" --check",
36+
"lint:fix:format": "prettier \"**/*.{json,yaml,md}\" --write",
3737
"lint": "pnpm run \"/^lint:check:.*/\"",
3838
"lint:fix": "pnpm run \"/^lint:fix:.*/\"",
3939
"changeset": "changeset",

prettier.config.js

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1 @@
1-
import commencisPrettierConfig from '@commencis/prettier-config';
2-
3-
export default commencisPrettierConfig;
1+
export { default } from '@commencis/prettier-config';

src/commands/create.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import chalk from 'chalk';
22

3+
import type { TemplateId } from '@/types';
34
import { setupTemplate } from '@/helpers';
4-
import { TemplateId } from '@/types';
55
import { printLogo, validateProjectName, validateTemplate } from '@/utils';
66

77
import { getProjectName, getSelectedTemplate } from '@/prompts';

src/config/template.config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { ExtensionId, TemplateId } from '@/types';
1+
import type { ExtensionId, TemplateId } from '@/types';
22

33
type TemplateConfig = {
44
name: string;

src/constants/template.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { templateConfigMap } from '@/config';
2-
import { TemplateId } from '@/types';
2+
import type { TemplateId } from '@/types';
33

44
export const TEMPLATE_IDS: TemplateId[] = Object.keys(
55
templateConfigMap

src/helpers/setupTemplate.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import path from 'node:path';
55
import hbs from 'handlebars';
66
import ora from 'ora';
77

8-
import { TemplateId } from '@/types';
8+
import type { TemplateId } from '@/types';
99
import { getTemplateDataById } from '@/utils';
1010

1111
import { cleanUpDirectory } from './cleanUpDirectory';

src/lib/git.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
import { SimpleGit, simpleGit, SimpleGitOptions } from 'simple-git';
1+
import type { SimpleGit, SimpleGitOptions } from 'simple-git';
2+
import { simpleGit } from 'simple-git';
23

34
const options: SimpleGitOptions = {
45
baseDir: process.cwd(),

src/prompts/getSelectedTemplate.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import enquirer from 'enquirer';
22

3-
import { TemplateId } from '@/types';
3+
import type { TemplateId } from '@/types';
44

55
export async function getSelectedTemplate(): Promise<TemplateId> {
66
const response = await enquirer.prompt<{ templateId: TemplateId }>({

src/utils/getTemplateDataById.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
import { templateConfigMap, TemplateData } from '@/config';
2-
import { ExtensionId, TemplateId } from '@/types';
1+
import { templateConfigMap, type TemplateData } from '@/config';
2+
import type { ExtensionId, TemplateId } from '@/types';
33

44
import packageJson from '../../package.json' with { type: 'json' };
55

0 commit comments

Comments
 (0)