Works with the AI Agents you already use

    Claude CodeClaude CodeCursorCursorCodex CLICodex CLIDeepSeekDeepSeekMuseMuse+22 more

    devflow clean js

    1

    Opinionated clean-code conventions for JavaScript and TypeScript (Node, React, Express, tests), applied whenever your agent writes or changes JS/TS. Your project's own config always wins.

    Free

    Security scanned
    devflow clean js

    devflow clean js

    Example session with this skill installed

    Refactor the processData function in src/utils.ts to follow clean code standards. It currently has nested if-statements and uses several positional arguments.

    • Read your context and instructions
    • Compiled the devflow clean js

    I have refactored src/utils.ts to improve readability and maintainability. I replaced the nested conditionals with guard clauses, consolidated positional parameters into a single options object, and ensured the function follows the 30-line limit. I also ran the project's Biome linter to ensure style consistency.

    Refactored Utility

    import { formatCurrency } from './formatters';
    import type { DataOptions, ProcessingResult } from './types';
    
    /**
     * Processes raw input data into a validated result object.
     * Uses guard clauses to keep nesting depth at 1.
     */
    export const processData = ({
      data,
      retryCount = 0,
      isPremium = false,
      onComplete
    }: DataOptions): ProcessingResult => {
      if (!data) {
        throw new Error('Processing failed', { cause: 'Data payload is null' });
      }
    
      if (retryCount > 3) {
        return { status: 'failed', reason: 'MAX_RETRIES' };
      }
    
      const processedValue = data.items
        .filter(item => item.isActive)
        .map(item => item.value * (isPremium ? 1.2 : 1.0));
    
      const total = processedValue.reduce((acc, val) => acc + val, 0);
    
      if (onComplete) {
        onComplete(total);
      }
    
      return {
        status: 'success',
        total,
        formattedTotal: formatCurrency(total),
        timestamp: Date.now(),
      };
    };
    

    Next steps

    1. Review the new DataOptions type I added to src/types.ts to support the options object.
    2. Run npm test to verify that the logic remains unchanged by the structural refactor.
    3. Check the scripts/lint.sh output log to see the minor whitespace fixes applied automatically.

    Connects securely to your tools. The creator never sees your data.

    About this skill

    Stop fighting against messy JavaScript and inconsistent TypeScript patterns. This skill enforces opinionated clean-code standards for Node, React, and Express environments, ensuring your agent writes maintainable, professional-grade code without manual supervision. It bridges the gap between raw code generation and production-ready quality by aligning with your existing project configurations while preventing common architectural smells.

    What it does

    • Enforces Clean Standards applies guard clauses, early returns, and a max nesting depth of two to ensure readability.
    • Optimizes Test Suites prevents redundant setup in Vitest, Jest, and Playwright by analyzing global configurations first.
    • Standardizes React & Node mandates named exports, options objects for complex parameters, and pure function patterns.
    • Automates Linting executes project-specific linters via scripts/lint.sh with safe auto-fixes enabled.
    • Manages Async Safely ensures all promises are handled and utilizes Promise.all for independent concurrent operations.

    How it works

    1. The agent analyzes your local biome.json, .eslintrc, and tsconfig.json to ensure project-specific styles take precedence.
    2. Code is generated or refactored following strict rules like const by default, no magic numbers, and 30-line function limits.
    3. The agent runs scripts/test-config.sh before writing tests to identify what not to duplicate from global setups.
    4. Final output is passed through the project's linter to resolve style violations automatically.

    Frameworks & tools

    Works with JavaScript (ESM/CJS) and TypeScript. Supported frameworks include React, Node.js, and Express. Compatible with Biome, ESLint, Prettier, Vitest, Jest, and Playwright.

    Why this beats prompting it yourself

    Generic prompts often produce deeply nested if-statements or messy test mocks that drift from your config. This skill uses a multi-step workflow that actually reads your configuration files and runs your local linting scripts to guarantee the code integrates perfectly with your specific environment.

    Use cases

    • Refactoring legacy React components into clean, functional patterns.
    • Writing integration tests that strictly follow existing Vitest or Playwright setups.
    • Converting complex nested logic into flat, readable guard-clause structures.
    • Standardizing a new microfrontend or service with consistent named exports and types.

    Known limitations

    Requires a bash environment to execute linting and config check scripts. Does not support non-JS/TS languages.

    Find more skills like this on the Claude Skills Marketplace, the Codex Skills Marketplace and the Gemini Skills Marketplace, or browse Claude Skills for Frontend & Web Apps.

    Requires bash. Automated linting requires project-level Biome or ESLint configurations. Optimized for JS/TS environments only.

    How to use

    1. 1

      Connect your agent to the Agensi MCP

      Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup

    2. 2

      Sign in to Agensi

      Your agent shows a sign-in link. Sign in and click Allow.

    3. 3

      Ask for what you need

      Your agent loads this skill and uses it on your task. It always asks before buying a skill.

    Reviews

    No reviews yet

    Be one of the first to try it. Every listed skill goes through the trust checks below.

    Security scanned

    Checked by our 8-point scan before listing

    Fresh listing

    Recently published to Agensi

    Free to use

    No account required to browse

    Trust & safety

    Security scan

    Security scan passed 1 day ago

    • Free with an Agensi account

    Software
    biomeNode.jseslint

    Permissions

    Terminal / Shell
    Browser
    Network Access
    Read Files
    Write Files
    Environment Variables
    Listed1 day ago

    What's inside

    Frequently Asked Questions

    This skill automates the enforcement of clean-code patterns like guard clauses and limited nesting, while dynamically checking your existing config files to ensure all generated code matches your project's specific linting and testing architecture.

    The skill is compatible with any AI agent that has access to a bash-compatible terminal and file system, as it relies on executing local scripts like `scripts/lint.sh` to verify code quality.

    Yes, it is designed to analyze your local `biome.json`, `.eslintrc`, and `tsconfig.json` files upon activation to ensure its output aligns with your established team standards rather than generic defaults.

    This skill is specifically optimized for JavaScript and TypeScript ecosystems, including frameworks like React, Node.js, and Express, but it does not support other languages like Python or Go.

    The skill requires a project structure that includes a bash environment and specific script hooks, such as `scripts/lint.sh`, to allow the agent to perform automated fixes and configuration checks.

    New in Frontend & Web Apps

    Free