validate() — vue Function Reference
Architecture documentation for the validate() function in util.ts from the vue codebase.
Entity Profile
Dependency Diagram
graph TD 165ad625_fe2f_2841_ca25_48bc6fda664f["validate()"] a4aaa23d_d810_1245_8cde_5c37b4bd3875["util.ts"] 165ad625_fe2f_2841_ca25_48bc6fda664f -->|defined in| a4aaa23d_d810_1245_8cde_5c37b4bd3875 dbfa2018_ca28_4a7e_bd4e_3f2e5fcb1d8a["apply()"] dbfa2018_ca28_4a7e_bd4e_3f2e5fcb1d8a -->|calls| 165ad625_fe2f_2841_ca25_48bc6fda664f style 165ad625_fe2f_2841_ca25_48bc6fda664f fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
packages/server-renderer/src/webpack-plugin/util.ts lines 10–33
export const validate = compiler => {
if (compiler.options.target !== 'node') {
warn('webpack config `target` should be "node".')
}
if (compiler.options.output) {
if (compiler.options.output.library) {
// Webpack >= 5.0.0
if (compiler.options.output.library.type !== 'commonjs2') {
warn('webpack config `output.library.type` should be "commonjs2".')
}
} else if (compiler.options.output.libraryTarget !== 'commonjs2') {
// Webpack < 5.0.0
warn('webpack config `output.libraryTarget` should be "commonjs2".')
}
}
if (!compiler.options.externals) {
tip(
'It is recommended to externalize dependencies in the server build for ' +
'better build performance.'
)
}
}
Domain
Subdomains
Called By
Source
Frequently Asked Questions
What does validate() do?
validate() is a function in the vue codebase, defined in packages/server-renderer/src/webpack-plugin/util.ts.
Where is validate() defined?
validate() is defined in packages/server-renderer/src/webpack-plugin/util.ts at line 10.
What calls validate()?
validate() is called by 1 function(s): apply.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free