Options

rspackConfig

Required
string

The path to the rspack config file.

assets

Array<oneOf [object , string]>
Default: []

List of static application assets.

additionalEntryPoints

No description available.

baseHref

string

Base url for the application being built.

buildLibsFromSource

boolean
Default: true

Read buildable libraries from source instead of building them separately. If set to false, the tsConfig option must also be set to remap paths.

deployUrl

string

URL where the application will be deployed.

extractLicenses

boolean
Default: false

Extract all licenses in a separate file.

extractCss

boolean

Extract CSS into a .css file.

externalDependencies

oneOf [string, Array<string>]

Dependencies to keep external to the bundle. (all (default), none, or an array of module names)

fileReplacements

Default: []

Replace files with other files in the build.

generatePackageJson

boolean

Generates a package.json and pruned lock file with the project's node_module dependencies populated for installing in a container. If a package.json exists in the project's directory, it will be reused with dependencies populated.

generateIndexHtml

boolean

Generates index.html file to the output path. This can be turned off if using a webpack plugin to generate HTML such as html-webpack-plugin.

index

indexHtml
string

HTML File which will be contain the application.

main

string

The main entry file.

mode

string
Accepted values: development, production, none

Mode to run the build in.

memoryLimit

number

Memory limit for type checking service process in MB.

namedChunks

boolean

Names the produced bundles according to their entry file.

outputPath

string

The output path for the bundle.

outputFileName

string

The main output entry file

optimization

oneOf [object , boolean]

Enables optimization of the build output.

outputHashing

string
Accepted values: none, all, media, bundles

Define the output filename cache-busting hashing mode.

poll

number

Enable and define the file watching poll time period.

polyfills

string

Polyfills to load before application

postcssConfig

string

Set a path to PostCSS config that applies to the app and all libs. Defaults to undefined, which auto-detects postcss.config.js files in each app/lib directory.

progress

boolean

Log progress to the console while building.

publicPath

string

Set a public path for assets resources with absolute paths.

rebaseRootRelative

boolean

Whether to rebase absolute path for assets in postcss cli resources.

runtimeChunk

boolean

Use a separate bundle containing the runtime.

skipTypeChecking

typeCheck
boolean

Skip the type checking. Default is false.

sourceMap

oneOf [boolean, string]
Default: true

Output sourcemaps. Use 'hidden' for use with error reporting tools without generating sourcemap comment.

scripts

Array<oneOf [object , string]>

External Scripts which will be included before the main application entry.

standardRspackConfigFunction

boolean
Default: false

Set to true if the rspack config exports a standard rspack function, not an Nx-specific one. See: https://rspack.dev/config/

statsJson

boolean

Generates a 'stats.json' file which can be analyzed using tools such as: 'webpack-bundle-analyzer' See: https://rspack.dev/guide/optimization/analysis

stylePreprocessorOptions

Options to pass to style preprocessors.

styles

Array<oneOf [object , string]>

External Styles which will be included with the application

target

string
Accepted values: web, node

The platform to target (e.g. web, node).

tsConfig

string

The tsconfig file to build the project.

transformers

Array<oneOf [string, object ]>

List of TypeScript Compiler Transfomers Plugins.

vendorChunk

boolean

Use a separate bundle containing only vendor libraries.