
Security News
Deno Goes the Way of the Dinosaur
Cloudflare is acquiring Deno’s team, which will provide another year of bug fixes and security updates before ending support for the runtime.
@deepracticex/config-preset
Advanced tools
Unified configuration system for Deepractice Node.js projects. Provides standardized, pre-configured setups for ESLint, Prettier, TypeScript, Commitlint, Vitest, and tsup.
pnpm add -D @deepracticex/config-preset
Install the tools you need:
# For ESLint
pnpm add -D eslint @typescript-eslint/parser @typescript-eslint/eslint-plugin eslint-config-prettier eslint-plugin-prettier
# For Prettier
pnpm add -D prettier
# For TypeScript
pnpm add -D typescript
# For Vitest
pnpm add -D vitest
# For tsup
pnpm add -D tsup
Create eslint.config.js:
import { eslint } from "@deepracticex/config-preset";
export default eslint.base;
What's included:
@typescript-eslintdist/, node_modules/, coverage/Create .prettierrc.js:
import { prettier } from "@deepracticex/config-preset";
export default prettier.base;
Formatting rules:
Create tsconfig.json:
{
"extends": "@deepracticex/config-preset/typescript-base.json",
"compilerOptions": {
"outDir": "./dist",
"rootDir": "./src"
},
"include": ["src/**/*"],
"exclude": ["node_modules", "dist", "tests"]
}
What's included:
Create vitest.config.ts:
import { vitest } from "@deepracticex/config-preset";
export default vitest.base;
What's included:
tests/unit/**/*.test.tstests/e2e/**/*.test.tsFor Cucumber/Gherkin BDD testing, install the separate testing utilities package:
pnpm add -D @deepracticex/testing-utils
import {
Given,
When,
Then,
Before,
After,
} from "@deepracticex/testing-utils/bdd";
Before(async function () {
// Setup before each scenario
});
Given("I have {int} cucumbers", async function (count: number) {
this.count = count;
});
When("I eat {int} cucumbers", async function (count: number) {
this.count -= count;
});
Then("I should have {int} cucumbers", async function (expected: number) {
expect(this.count).toBe(expected);
});
After(async function () {
// Cleanup after each scenario
});
See @deepracticex/testing-utils for complete documentation.
Create tsup.config.ts:
import { tsup } from "@deepracticex/config-preset";
export default tsup.base;
What's included:
~ → ./srcimport { tsup } from "@deepracticex/config-preset";
export default tsup.createConfig({
entry: ["src/index.ts", "src/cli.ts"],
external: ["vitest"],
});
Create commitlint.config.js:
import { commitlint } from "@deepracticex/config-preset";
export default commitlint.base;
Commit types:
feat: New featurefix: Bug fixdocs: Documentation changesstyle: Code style changes (formatting)refactor: Code refactoringperf: Performance improvementstest: Adding or updating testsbuild: Build system or external dependenciesci: CI/CD changeschore: Other changesrevert: Revert a previous commitFormat:
<type>: <subject>
<body>
<footer>
Follow this standard structure:
your-project/
├── features/ # BDD specifications (Gherkin)
│ └── *.feature
├── src/ # Source code
│ ├── api/ # Public API
│ ├── core/ # Internal implementation
│ ├── types/ # Type definitions
│ └── index.ts
├── tests/
│ ├── unit/ # Unit tests
│ │ └── *.test.ts
│ └── e2e/ # End-to-end tests
│ ├── steps/ # Cucumber step definitions
│ │ └── *.steps.ts
│ └── *.test.ts
├── dist/ # Build output
├── eslint.config.js
├── .prettierrc.js
├── tsconfig.json
├── vitest.config.ts
├── tsup.config.ts
└── package.json
Add these scripts to package.json:
{
"scripts": {
"build": "tsup",
"dev": "tsup --watch",
"test": "vitest run",
"test:dev": "vitest",
"test:ui": "vitest --ui",
"test:coverage": "vitest run --coverage",
"lint": "eslint .",
"lint:fix": "eslint . --fix",
"format": "prettier --write .",
"format:check": "prettier --check .",
"typecheck": "tsc --noEmit",
"clean": "rimraf dist"
}
}
Use Gherkin syntax for BDD specifications:
Feature: User Authentication
Scenario: Successful login
Given a user with email "test@example.com" and password "secret123"
When the user attempts to login
Then the login should succeed
And a session token should be returned
Scenario: Failed login with wrong password
Given a user with email "test@example.com" and password "wrong"
When the user attempts to login
Then the login should fail
And an error message should be shown
Organize steps by domain:
For BDD step definitions, use @deepracticex/testing-utils:
// tests/e2e/steps/auth.steps.ts
import { Given, When, Then } from "@deepracticex/testing-utils/bdd";
import { expect } from "vitest";
Given(
"a user with email {string} and password {string}",
async function (email: string, password: string) {
this.user = { email, password };
},
);
When("the user attempts to login", async function () {
this.result = await login(this.user);
});
Then("the login should succeed", async function () {
expect(this.result.success).toBe(true);
});
See @deepracticex/testing-utils for complete BDD documentation.
Use the ~ alias for internal imports:
// Instead of:
import { foo } from "../../core/foo";
// Use:
import { foo } from "~/core/foo";
The ~ alias is automatically configured in:
Follow the API/Core separation pattern:
src/api/: Public API that users importsrc/core/: Internal implementation (not exported)src/types/: Public type definitionssrc/index.ts: Main entry point (exports api + types, not core)This allows you to refactor internals without breaking user code.
The package provides multiple entry points:
// Main entry - all configurations
import {
eslint,
prettier,
typescript,
vitest,
tsup,
commitlint,
} from "@deepracticex/config-preset";
// Specific tools (subpath imports)
import { vitest } from "@deepracticex/config-preset/vitest";
import { eslint } from "@deepracticex/config-preset/eslint";
// BDD testing utilities (separate package)
// import { Given, When, Then } from "@deepracticex/testing-utils/bdd";
All configurations are fully typed:
import { vitest, type VitestPreset } from "@deepracticex/config-preset";
const preset: VitestPreset = "base"; // "base" | "coverage"
Replace your existing config files:
Before:
// eslint.config.js - 50+ lines of configuration
export default [
// ... complex setup
];
After:
// eslint.config.js - 3 lines
import { eslint } from "@deepracticex/config-preset";
export default eslint.base;
For Cucumber/Gherkin BDD testing:
pnpm add -D @deepracticex/testing-utils
features/ directory@deepracticex/testing-utils/bddSee @deepracticex/testing-utils for detailed setup instructions.
Make sure you're using the new flat config format (eslint.config.js), not the legacy .eslintrc.
Add to your tsconfig.json:
{
"compilerOptions": {
"types": ["vitest/globals"]
}
}
For Vitest, add to vitest.config.ts:
import { defineConfig } from "vitest/config";
import path from "path";
export default defineConfig({
resolve: {
alias: {
"~": path.resolve(__dirname, "./src"),
},
},
});
See CONTRIBUTING.md for development guidelines.
MIT © Deepractice
FAQs
Pure configuration presets for Deepractice Node.js projects
We found that @deepracticex/config-preset demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 open source maintainers collaborating on the project.

Security News
Cloudflare is acquiring Deno’s team, which will provide another year of bug fixes and security updates before ending support for the runtime.

Security News
Anthropic’s free OSS Scanner uses Mythos and other Claude models to find open source vulnerabilities and send maintainers reports with proposed fixes.

Security News
On Front Lines’ Early Adopters: CISO podcast, Andrew Becherer shares lessons from Datadog, weighs the long-term costs of AI-built tools, and explains how founders can actually gain a CISO’s trust.