Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@nx/js

Package Overview
Dependencies
Maintainers
4
Versions
803
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@nx/js

The JS plugin for Nx contains executors and generators that provide the best experience for developing JavaScript and TypeScript projects.

  • 20.3.0-canary.20241214-4cd640a
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
2.1M
decreased by-8.15%
Maintainers
4
Weekly downloads
 
Created

What is @nx/js?

@nx/js is a package that provides tools and utilities for managing JavaScript projects within the Nx workspace. It offers functionalities for building, testing, and managing dependencies in JavaScript projects.

What are @nx/js's main functionalities?

Building JavaScript Projects

This feature allows you to build JavaScript projects using the Nx build executor. The code sample demonstrates how to configure a project named 'myApp' with build options.

module.exports = {
  projects: {
    myApp: {
      root: 'apps/my-app',
      sourceRoot: 'apps/my-app/src',
      projectType: 'application',
      targets: {
        build: {
          executor: '@nx/js:build',
          options: {
            outputPath: 'dist/apps/my-app',
            main: 'apps/my-app/src/main.ts',
            tsConfig: 'apps/my-app/tsconfig.app.json'
          }
        }
      }
    }
  }
};

Testing JavaScript Projects

This feature allows you to test JavaScript projects using the Nx test executor. The code sample demonstrates how to configure a project named 'myApp' with test options.

module.exports = {
  projects: {
    myApp: {
      root: 'apps/my-app',
      sourceRoot: 'apps/my-app/src',
      projectType: 'application',
      targets: {
        test: {
          executor: '@nx/js:test',
          options: {
            jestConfig: 'apps/my-app/jest.config.js',
            passWithNoTests: true
          }
        }
      }
    }
  }
};

Managing Dependencies

This feature allows you to manage dependencies and lint JavaScript projects using the Nx lint executor. The code sample demonstrates how to configure a project named 'myApp' with lint options.

module.exports = {
  projects: {
    myApp: {
      root: 'apps/my-app',
      sourceRoot: 'apps/my-app/src',
      projectType: 'application',
      targets: {
        lint: {
          executor: '@nx/js:lint',
          options: {
            lintFilePatterns: ['apps/my-app/**/*.ts']
          }
        }
      }
    }
  }
};

Other packages similar to @nx/js

Keywords

FAQs

Package last updated on 14 Dec 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc