@nrwl/node:webpack
Node application build target options for Build Facade.
Options can be configured in project.json
when defining the executor, or when invoking it. Read more about how to configure targets and executors here: https://nx.dev/configuration/projectjson#targets.
Options
buildLibsFromSource
true
Read buildable libraries from source instead of building them separately.
externalDependencies
all
Dependencies to keep external to the bundle. (all
(default), none
, or an array of module names)
extractLicenses
false
Extract all licenses in a separate file, in the case of production builds only.
fileReplacements
[]
Replace files with other files in the build.
generatePackageJson
false
Generates a package.json
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.
main
The name of the main entry-point file.
maxWorkers
Number of workers to use for type checking. (defaults to # of CPUS)
memoryLimit
2048
Memory limit for type checking service process in MB. (defaults to 2048
)
outputPath
The output path of the generated files.
optimization
false
Defines the optimization level of the build.
outputFileName
main.js
Name of the main output file. (defaults to main.js
)
poll
Frequency of file watcher in ms.
progress
false
Log progress to the console while building.
sourceMap
true
Produce source maps.
statsJson
false
Generates a stats.json
file which can be analyzed using tools such as: webpack-bundle-analyzer
or <https://webpack.github.io/analyse>
.
tsConfig
The name of the Typescript configuration file.
transformers
[]
List of TypeScript Compiler Transfomers Plugins.
verbose
false
Emits verbose output
watch
false
Run build when files change.
webpackConfig
Path to a function which takes a webpack config, context and returns the resulting webpack config. See https://nx.dev/guides/customize-webpack