@neosianexus/quality 1.0.0-beta.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +551 -0
- package/bin/cli.js +1099 -0
- package/biome.json +639 -0
- package/commitlint.config.js +134 -0
- package/knip.config.json +7 -0
- package/package.json +115 -0
- package/tsconfig.base.json +57 -0
- package/tsconfig.nextjs.json +29 -0
- package/tsconfig.react.json +12 -0
- package/vscode/extensions.json +11 -0
- package/vscode/settings.json +49 -0
|
@@ -0,0 +1,134 @@
|
|
|
1
|
+
/** @type {import('@commitlint/types').UserConfig} */
|
|
2
|
+
export default {
|
|
3
|
+
extends: ["@commitlint/config-conventional"],
|
|
4
|
+
rules: {
|
|
5
|
+
// Type must be one of the following
|
|
6
|
+
"type-enum": [
|
|
7
|
+
2,
|
|
8
|
+
"always",
|
|
9
|
+
[
|
|
10
|
+
"feat", // New feature
|
|
11
|
+
"fix", // Bug fix
|
|
12
|
+
"docs", // Documentation only
|
|
13
|
+
"style", // Code style (formatting, semicolons, etc.)
|
|
14
|
+
"refactor", // Code refactoring (no feature/fix)
|
|
15
|
+
"perf", // Performance improvement
|
|
16
|
+
"test", // Adding or updating tests
|
|
17
|
+
"build", // Build system or dependencies
|
|
18
|
+
"ci", // CI/CD configuration
|
|
19
|
+
"chore", // Other changes (maintenance)
|
|
20
|
+
"revert", // Revert a previous commit
|
|
21
|
+
"wip", // Work in progress (optional)
|
|
22
|
+
],
|
|
23
|
+
],
|
|
24
|
+
// Type must be lowercase
|
|
25
|
+
"type-case": [2, "always", "lower-case"],
|
|
26
|
+
// Type cannot be empty
|
|
27
|
+
"type-empty": [2, "never"],
|
|
28
|
+
// Subject cannot be empty
|
|
29
|
+
"subject-empty": [2, "never"],
|
|
30
|
+
// Subject must not end with a period
|
|
31
|
+
"subject-full-stop": [2, "never", "."],
|
|
32
|
+
// Subject max length
|
|
33
|
+
"subject-max-length": [2, "always", 72],
|
|
34
|
+
// Header max length
|
|
35
|
+
"header-max-length": [2, "always", 100],
|
|
36
|
+
// Body max line length
|
|
37
|
+
"body-max-line-length": [2, "always", 100],
|
|
38
|
+
// Footer max line length
|
|
39
|
+
"footer-max-line-length": [2, "always", 100],
|
|
40
|
+
},
|
|
41
|
+
prompt: {
|
|
42
|
+
questions: {
|
|
43
|
+
type: {
|
|
44
|
+
description: "Select the type of change you're committing",
|
|
45
|
+
enum: {
|
|
46
|
+
feat: {
|
|
47
|
+
description: "A new feature",
|
|
48
|
+
title: "Features",
|
|
49
|
+
emoji: "✨",
|
|
50
|
+
},
|
|
51
|
+
fix: {
|
|
52
|
+
description: "A bug fix",
|
|
53
|
+
title: "Bug Fixes",
|
|
54
|
+
emoji: "🐛",
|
|
55
|
+
},
|
|
56
|
+
docs: {
|
|
57
|
+
description: "Documentation only changes",
|
|
58
|
+
title: "Documentation",
|
|
59
|
+
emoji: "📚",
|
|
60
|
+
},
|
|
61
|
+
style: {
|
|
62
|
+
description: "Changes that do not affect the meaning of the code",
|
|
63
|
+
title: "Styles",
|
|
64
|
+
emoji: "💎",
|
|
65
|
+
},
|
|
66
|
+
refactor: {
|
|
67
|
+
description: "A code change that neither fixes a bug nor adds a feature",
|
|
68
|
+
title: "Code Refactoring",
|
|
69
|
+
emoji: "📦",
|
|
70
|
+
},
|
|
71
|
+
perf: {
|
|
72
|
+
description: "A code change that improves performance",
|
|
73
|
+
title: "Performance Improvements",
|
|
74
|
+
emoji: "🚀",
|
|
75
|
+
},
|
|
76
|
+
test: {
|
|
77
|
+
description: "Adding missing tests or correcting existing tests",
|
|
78
|
+
title: "Tests",
|
|
79
|
+
emoji: "🚨",
|
|
80
|
+
},
|
|
81
|
+
build: {
|
|
82
|
+
description: "Changes that affect the build system or dependencies",
|
|
83
|
+
title: "Builds",
|
|
84
|
+
emoji: "🛠",
|
|
85
|
+
},
|
|
86
|
+
ci: {
|
|
87
|
+
description: "Changes to CI configuration files and scripts",
|
|
88
|
+
title: "Continuous Integrations",
|
|
89
|
+
emoji: "⚙️",
|
|
90
|
+
},
|
|
91
|
+
chore: {
|
|
92
|
+
description: "Other changes that don't modify src or test files",
|
|
93
|
+
title: "Chores",
|
|
94
|
+
emoji: "♻️",
|
|
95
|
+
},
|
|
96
|
+
revert: {
|
|
97
|
+
description: "Reverts a previous commit",
|
|
98
|
+
title: "Reverts",
|
|
99
|
+
emoji: "🗑",
|
|
100
|
+
},
|
|
101
|
+
},
|
|
102
|
+
},
|
|
103
|
+
scope: {
|
|
104
|
+
description: "What is the scope of this change (e.g. component or file name)",
|
|
105
|
+
},
|
|
106
|
+
subject: {
|
|
107
|
+
description: "Write a short, imperative tense description of the change",
|
|
108
|
+
},
|
|
109
|
+
body: {
|
|
110
|
+
description: "Provide a longer description of the change",
|
|
111
|
+
},
|
|
112
|
+
isBreaking: {
|
|
113
|
+
description: "Are there any breaking changes?",
|
|
114
|
+
},
|
|
115
|
+
breakingBody: {
|
|
116
|
+
description:
|
|
117
|
+
"A BREAKING CHANGE commit requires a body. Please provide a longer description",
|
|
118
|
+
},
|
|
119
|
+
breaking: {
|
|
120
|
+
description: "Describe the breaking changes",
|
|
121
|
+
},
|
|
122
|
+
isIssueAffected: {
|
|
123
|
+
description: "Does this change affect any open issues?",
|
|
124
|
+
},
|
|
125
|
+
issuesBody: {
|
|
126
|
+
description:
|
|
127
|
+
"If issues are closed, the commit requires a body. Please provide a longer description",
|
|
128
|
+
},
|
|
129
|
+
issues: {
|
|
130
|
+
description: 'Add issue references (e.g. "fix #123", "re #123".)',
|
|
131
|
+
},
|
|
132
|
+
},
|
|
133
|
+
},
|
|
134
|
+
};
|
package/knip.config.json
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://unpkg.com/knip@5/schema.json",
|
|
3
|
+
"entry": ["src/index.{ts,tsx,js,jsx}", "src/main.{ts,tsx,js,jsx}", "app/**/*.{ts,tsx}"],
|
|
4
|
+
"project": ["src/**/*.{ts,tsx,js,jsx}", "app/**/*.{ts,tsx,js,jsx}"],
|
|
5
|
+
"ignore": ["**/*.d.ts", "**/*.config.{ts,js,mjs,cjs}"],
|
|
6
|
+
"ignoreDependencies": []
|
|
7
|
+
}
|
package/package.json
ADDED
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@neosianexus/quality",
|
|
3
|
+
"version": "1.0.0-beta.5",
|
|
4
|
+
"description": "Ultra-strict Biome + TypeScript + Husky + Commitlint configuration for React/Next.js projects",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"main": "./biome.json",
|
|
7
|
+
"bin": {
|
|
8
|
+
"quality": "./bin/cli.js",
|
|
9
|
+
"quality-init": "./bin/cli.js"
|
|
10
|
+
},
|
|
11
|
+
"engines": {
|
|
12
|
+
"node": ">=18.0.0"
|
|
13
|
+
},
|
|
14
|
+
"homepage": "https://github.com/NeosiaNexus/quality#readme",
|
|
15
|
+
"bugs": {
|
|
16
|
+
"url": "https://github.com/NeosiaNexus/quality/issues"
|
|
17
|
+
},
|
|
18
|
+
"funding": {
|
|
19
|
+
"type": "github",
|
|
20
|
+
"url": "https://github.com/sponsors/NeosiaNexus"
|
|
21
|
+
},
|
|
22
|
+
"exports": {
|
|
23
|
+
".": "./biome.json",
|
|
24
|
+
"./biome.json": "./biome.json",
|
|
25
|
+
"./biome": "./biome.json",
|
|
26
|
+
"./tsconfig.base": "./tsconfig.base.json",
|
|
27
|
+
"./tsconfig.react": "./tsconfig.react.json",
|
|
28
|
+
"./tsconfig.nextjs": "./tsconfig.nextjs.json",
|
|
29
|
+
"./tsconfig": "./tsconfig.base.json",
|
|
30
|
+
"./commitlint": "./commitlint.config.js",
|
|
31
|
+
"./commitlint.config": "./commitlint.config.js",
|
|
32
|
+
"./vscode/settings": "./vscode/settings.json",
|
|
33
|
+
"./vscode/extensions": "./vscode/extensions.json",
|
|
34
|
+
"./knip": "./knip.config.json",
|
|
35
|
+
"./knip.json": "./knip.config.json"
|
|
36
|
+
},
|
|
37
|
+
"files": [
|
|
38
|
+
"biome.json",
|
|
39
|
+
"tsconfig.base.json",
|
|
40
|
+
"tsconfig.react.json",
|
|
41
|
+
"tsconfig.nextjs.json",
|
|
42
|
+
"commitlint.config.js",
|
|
43
|
+
"knip.config.json",
|
|
44
|
+
"bin/cli.js",
|
|
45
|
+
"vscode"
|
|
46
|
+
],
|
|
47
|
+
"scripts": {
|
|
48
|
+
"build": "tsup",
|
|
49
|
+
"prepublishOnly": "bun run validate && bun run build && bun run publint",
|
|
50
|
+
"validate": "bun run check && bun run typecheck && bun run knip",
|
|
51
|
+
"lint": "biome lint --config-path=biome.dev.json .",
|
|
52
|
+
"lint:fix": "biome lint --config-path=biome.dev.json --write --unsafe .",
|
|
53
|
+
"format": "biome format --config-path=biome.dev.json --write .",
|
|
54
|
+
"check": "biome check --config-path=biome.dev.json .",
|
|
55
|
+
"check:fix": "biome check --config-path=biome.dev.json --write --unsafe .",
|
|
56
|
+
"typecheck": "tsc --noEmit",
|
|
57
|
+
"knip": "knip",
|
|
58
|
+
"publint": "publint",
|
|
59
|
+
"attw": "attw --pack .",
|
|
60
|
+
"dev": "bun run bin/cli.ts"
|
|
61
|
+
},
|
|
62
|
+
"keywords": [
|
|
63
|
+
"biome",
|
|
64
|
+
"linter",
|
|
65
|
+
"formatter",
|
|
66
|
+
"typescript",
|
|
67
|
+
"tsconfig",
|
|
68
|
+
"husky",
|
|
69
|
+
"lint-staged",
|
|
70
|
+
"commitlint",
|
|
71
|
+
"conventional-commits",
|
|
72
|
+
"react",
|
|
73
|
+
"nextjs",
|
|
74
|
+
"quality",
|
|
75
|
+
"strict",
|
|
76
|
+
"enterprise",
|
|
77
|
+
"pre-commit"
|
|
78
|
+
],
|
|
79
|
+
"author": "neosianexus",
|
|
80
|
+
"license": "MIT",
|
|
81
|
+
"repository": {
|
|
82
|
+
"type": "git",
|
|
83
|
+
"url": "git+https://github.com/NeosiaNexus/quality.git"
|
|
84
|
+
},
|
|
85
|
+
"peerDependencies": {
|
|
86
|
+
"@biomejs/biome": "^2.0.0",
|
|
87
|
+
"typescript": "^5.0.0"
|
|
88
|
+
},
|
|
89
|
+
"peerDependenciesMeta": {
|
|
90
|
+
"@commitlint/cli": {
|
|
91
|
+
"optional": true
|
|
92
|
+
},
|
|
93
|
+
"@commitlint/config-conventional": {
|
|
94
|
+
"optional": true
|
|
95
|
+
}
|
|
96
|
+
},
|
|
97
|
+
"dependencies": {
|
|
98
|
+
"@clack/prompts": "^0.10.0",
|
|
99
|
+
"citty": "^0.1.6",
|
|
100
|
+
"deepmerge": "^4.3.1",
|
|
101
|
+
"picocolors": "^1.1.1"
|
|
102
|
+
},
|
|
103
|
+
"devDependencies": {
|
|
104
|
+
"@arethetypeswrong/cli": "^0.18.2",
|
|
105
|
+
"@biomejs/biome": "^2.3.13",
|
|
106
|
+
"@commitlint/cli": "^19.8.1",
|
|
107
|
+
"@commitlint/config-conventional": "^19.8.1",
|
|
108
|
+
"@commitlint/types": "^19.8.1",
|
|
109
|
+
"@types/node": "^22.15.21",
|
|
110
|
+
"knip": "^5.82.1",
|
|
111
|
+
"publint": "^0.3.17",
|
|
112
|
+
"tsup": "^8.5.0",
|
|
113
|
+
"typescript": "^5.8.3"
|
|
114
|
+
}
|
|
115
|
+
}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json.schemastore.org/tsconfig",
|
|
3
|
+
"display": "@neosianexus/quality - Base TypeScript Config",
|
|
4
|
+
"compilerOptions": {
|
|
5
|
+
/* Type Checking - Maximum Strictness */
|
|
6
|
+
"strict": true,
|
|
7
|
+
"noImplicitAny": true,
|
|
8
|
+
"strictNullChecks": true,
|
|
9
|
+
"strictFunctionTypes": true,
|
|
10
|
+
"strictBindCallApply": true,
|
|
11
|
+
"strictPropertyInitialization": true,
|
|
12
|
+
"strictBuiltinIteratorReturn": true,
|
|
13
|
+
"noImplicitThis": true,
|
|
14
|
+
"useUnknownInCatchVariables": true,
|
|
15
|
+
"alwaysStrict": true,
|
|
16
|
+
"noUnusedLocals": true,
|
|
17
|
+
"noUnusedParameters": true,
|
|
18
|
+
"exactOptionalPropertyTypes": true,
|
|
19
|
+
"noImplicitReturns": true,
|
|
20
|
+
"noFallthroughCasesInSwitch": true,
|
|
21
|
+
"noUncheckedIndexedAccess": true,
|
|
22
|
+
"noImplicitOverride": true,
|
|
23
|
+
"noPropertyAccessFromIndexSignature": true,
|
|
24
|
+
"allowUnusedLabels": false,
|
|
25
|
+
"allowUnreachableCode": false,
|
|
26
|
+
|
|
27
|
+
/* Modules */
|
|
28
|
+
"module": "ESNext",
|
|
29
|
+
"moduleResolution": "bundler",
|
|
30
|
+
"resolveJsonModule": true,
|
|
31
|
+
"allowImportingTsExtensions": true,
|
|
32
|
+
"verbatimModuleSyntax": true,
|
|
33
|
+
"noUncheckedSideEffectImports": true,
|
|
34
|
+
|
|
35
|
+
/* Emit */
|
|
36
|
+
"noEmit": true,
|
|
37
|
+
"declaration": true,
|
|
38
|
+
"declarationMap": true,
|
|
39
|
+
"sourceMap": true,
|
|
40
|
+
"removeComments": false,
|
|
41
|
+
|
|
42
|
+
/* Interop Constraints */
|
|
43
|
+
"isolatedModules": true,
|
|
44
|
+
"esModuleInterop": true,
|
|
45
|
+
"allowSyntheticDefaultImports": true,
|
|
46
|
+
"forceConsistentCasingInFileNames": true,
|
|
47
|
+
|
|
48
|
+
/* Language and Environment */
|
|
49
|
+
"target": "ES2022",
|
|
50
|
+
"lib": ["ES2022"],
|
|
51
|
+
"useDefineForClassFields": true,
|
|
52
|
+
|
|
53
|
+
/* Completeness */
|
|
54
|
+
"skipLibCheck": true
|
|
55
|
+
},
|
|
56
|
+
"exclude": ["node_modules", "dist", "build", ".next", "coverage", "**/*.spec.ts", "**/*.test.ts"]
|
|
57
|
+
}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json.schemastore.org/tsconfig",
|
|
3
|
+
"display": "@neosianexus/quality - Next.js TypeScript Config",
|
|
4
|
+
"extends": "./tsconfig.base.json",
|
|
5
|
+
"compilerOptions": {
|
|
6
|
+
/* JSX - Next.js uses preserve for its own compilation */
|
|
7
|
+
"jsx": "preserve",
|
|
8
|
+
|
|
9
|
+
/* Libraries */
|
|
10
|
+
"lib": ["ES2022", "DOM", "DOM.Iterable"],
|
|
11
|
+
|
|
12
|
+
/* Next.js specific */
|
|
13
|
+
"module": "ESNext",
|
|
14
|
+
"moduleResolution": "bundler",
|
|
15
|
+
"allowJs": true,
|
|
16
|
+
"incremental": true,
|
|
17
|
+
|
|
18
|
+
/* Disable options incompatible with Next.js CSS imports */
|
|
19
|
+
"verbatimModuleSyntax": false,
|
|
20
|
+
"allowImportingTsExtensions": false,
|
|
21
|
+
|
|
22
|
+
/* Next.js plugins */
|
|
23
|
+
"plugins": [
|
|
24
|
+
{
|
|
25
|
+
"name": "next"
|
|
26
|
+
}
|
|
27
|
+
]
|
|
28
|
+
}
|
|
29
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json.schemastore.org/tsconfig",
|
|
3
|
+
"display": "@neosianexus/quality - React TypeScript Config",
|
|
4
|
+
"extends": "./tsconfig.base.json",
|
|
5
|
+
"compilerOptions": {
|
|
6
|
+
/* JSX */
|
|
7
|
+
"jsx": "react-jsx",
|
|
8
|
+
|
|
9
|
+
/* Libraries */
|
|
10
|
+
"lib": ["ES2022", "DOM", "DOM.Iterable"]
|
|
11
|
+
}
|
|
12
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
{
|
|
2
|
+
"recommendations": [
|
|
3
|
+
"biomejs.biome",
|
|
4
|
+
"usernamehw.errorlens",
|
|
5
|
+
"editorconfig.editorconfig",
|
|
6
|
+
"streetsidesoftware.code-spell-checker",
|
|
7
|
+
"eamodio.gitlens",
|
|
8
|
+
"gruntfuggly.todo-tree"
|
|
9
|
+
],
|
|
10
|
+
"unwantedRecommendations": ["esbenp.prettier-vscode", "dbaeumer.vscode-eslint"]
|
|
11
|
+
}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
{
|
|
2
|
+
"editor.defaultFormatter": "biomejs.biome",
|
|
3
|
+
"editor.formatOnSave": true,
|
|
4
|
+
"editor.formatOnPaste": true,
|
|
5
|
+
"editor.codeActionsOnSave": {
|
|
6
|
+
"source.organizeImports.biome": "explicit",
|
|
7
|
+
"quickfix.biome": "explicit"
|
|
8
|
+
},
|
|
9
|
+
"editor.rulers": [100],
|
|
10
|
+
"editor.tabSize": 2,
|
|
11
|
+
"editor.insertSpaces": false,
|
|
12
|
+
"files.eol": "\n",
|
|
13
|
+
"files.trimTrailingWhitespace": true,
|
|
14
|
+
"files.insertFinalNewline": true,
|
|
15
|
+
"[javascript]": {
|
|
16
|
+
"editor.defaultFormatter": "biomejs.biome"
|
|
17
|
+
},
|
|
18
|
+
"[javascriptreact]": {
|
|
19
|
+
"editor.defaultFormatter": "biomejs.biome"
|
|
20
|
+
},
|
|
21
|
+
"[typescript]": {
|
|
22
|
+
"editor.defaultFormatter": "biomejs.biome"
|
|
23
|
+
},
|
|
24
|
+
"[typescriptreact]": {
|
|
25
|
+
"editor.defaultFormatter": "biomejs.biome"
|
|
26
|
+
},
|
|
27
|
+
"[json]": {
|
|
28
|
+
"editor.defaultFormatter": "biomejs.biome"
|
|
29
|
+
},
|
|
30
|
+
"[jsonc]": {
|
|
31
|
+
"editor.defaultFormatter": "biomejs.biome"
|
|
32
|
+
},
|
|
33
|
+
"[css]": {
|
|
34
|
+
"editor.defaultFormatter": "biomejs.biome"
|
|
35
|
+
},
|
|
36
|
+
"[markdown]": {
|
|
37
|
+
"files.trimTrailingWhitespace": false
|
|
38
|
+
},
|
|
39
|
+
"biome.enabled": true,
|
|
40
|
+
"biome.lspBin": null,
|
|
41
|
+
"typescript.tsdk": "node_modules/typescript/lib",
|
|
42
|
+
"typescript.enablePromptUseWorkspaceTsdk": true,
|
|
43
|
+
"typescript.preferences.importModuleSpecifier": "non-relative",
|
|
44
|
+
"typescript.suggest.autoImports": true,
|
|
45
|
+
"typescript.updateImportsOnFileMove.enabled": "always",
|
|
46
|
+
"typescript.preferences.preferTypeOnlyAutoImports": true,
|
|
47
|
+
"javascript.preferences.importModuleSpecifier": "non-relative",
|
|
48
|
+
"javascript.updateImportsOnFileMove.enabled": "always"
|
|
49
|
+
}
|