Nx Console

repository·master·Indexed 23 days ago

https://github.com/nrwl/nx-console

A visual interface for Nx and Lerna monorepos available for Visual Studio Code and JetBrains IDEs. It provides visual workflows, interactive generator UIs, and autocompletion for CLI tools. The ecosystem includes the Nx Language Server (nxls) for enhanced configuration intelligence and the Nx MCP server, which allows LLMs to access monorepo structure, project relationships, and CI pipeline executions.

Tokens
15.3K
Snippets
39
Records
141
Agent score
81%

What's inside nx-console

  1. Nx Language Server (nxls) capabilities

    master

    The Nx Language Server utilizes json-languageservice to provide enhanced intelligence for Nx workspace configuration files.

    Supported Features:

    • Code Completion (onCompletion):

      • Provides completion results within project.json and workspace.json files.
      • Lists installed executors when defining new targets for a project.
      • Provides relevant option completion results for a selected executor.
      • Note: Support for nx.json is planned for a future release.
    • Hover Support (onHover):

      • Provides descriptions for executor options within project.json and workspace.json files.
  2. Use Nx Console for visual workflows and autocompletion

    master

    Nx Console provides a user interface for Nx command-line tools, making advanced monorepo management easier. It helps you avoid remembering complex CLI flags and paths by providing:

    • Visual exploration: Easily browse custom generator collections without using the terminal.
    • Autocompletion: Get suggestions for command arguments and flags.
    • Input validation: Ensure paths (absolute or relative) and flag names are correct before execution.
  3. Visualize Nx Project and Task Graphs

    master
    Nx Console visualizes project and task graphs within your editor. It automatically focuses the graph on the file you are currently working on and allows you to run tasks or explore project dependencies with a single click.
  4. Use AI Enhancements with MCP

    master

    Nx Console enhances AI features in editors like VSCode and Cursor by providing workspace architecture context, generators, and up-to-date Nx documentation.

    It includes an MCP (Model Context Protocol) server for both VSCode and Cursor. You can also install the MCP server independently using the nx-mcp NPM package.

  5. Nx Cloud Integration

    master

    Nx Console integrates with Nx Cloud to provide:

    • An overview of current CI Pipeline Executions.
    • Notifications when CI tasks complete or encounter errors.
    • Guided onboarding for Nx Cloud directly within the editor.
  6. Understand Nx MCP Minimal Mode

    master

    By default, the Nx MCP server runs in minimal mode. This mode hides workspace analysis tools that might overlap with the native capabilities of an AI agent, reducing context window usage and tool clutter.

    Hidden tools in Minimal Mode:

    • nx_available_plugins
    • nx_workspace_path
    • nx_workspace
    • nx_project_details
    • nx_generators
    • nx_generator_schema

    To expose all tools, run the server with the --no-minimal flag:

    npx nx-mcp@latest --no-minimal
  7. Install and run the Nx MCP Server

    master

    The Nx MCP server allows LLMs to access your monorepo's structure, project relationships, tasks, and documentation. You can run it via npx or integrate it into your AI tools using the following methods:

    Via npx (Standard Configuration)

    Add this to your MCP client configuration (e.g., mcp.json for Claude Desktop):

    {
      "servers": {
        "nx-mcp": {
          "type": "stdio",
          "command": "npx",
          "args": ["nx-mcp@latest"]
        }
      }
    }

    Tool-Specific Commands

    • Claude Code: claude mcp add nx-mcp npx nx-mcp@latest
    • VSCode: code --add-mcp '{"name":"nx-mcp","command":"npx","args":["nx-mcp"]}'
    • Warp: Use the /add-mcp slash command or add it via Settings -> AI -> Manage MCP Servers.

    Via Nx Console Extension

    If using Cursor, you can install the Nx Console extension, which automatically manages the MCP server for you.

  8. Run executor commands from the Command Palette

    master

    You can configure and execute Nx commands without leaving the Command Palette.

    1. Open the Command Palette using ⇧⌘P (macOS) or Ctrl+Shift+P (Windows/Linux).
    2. Select a specific command, for example, nx: test.
    3. Choose the target project.
    4. Select from the listed options to modify the executor command parameters.
    5. Once configured, select the Execute command at the top of the list to run the task.