ZombieBoxConfig

September 22, 2021 ยท View on GitHub

ZombieBox project configuration schema

KeyTypeDescription
projectProjectConfigRequired! Vital project configuration
gccObjectClosure Compiler flags. Some flags (--js, --externs et al.) are set internally by ZombieBox, overriding them might break everything.
buildBuildOptionsBuild options
postcssPostCSSConfigConfigures CSS files processing and bundling
includeArray<EntityConfig>Resources, source and other files for additional entities (libraries, extra scripts and static files)
extensionsObjectZombieBox extensions specific configuration options
platformsObjectZombieBox platforms specific configuration options
aliasesObjectA map of any additional aliases
defineObjectCompilation time defines that will be added as runtime constants
devServerDevServerConfigDevelopment server options
skipVersionsCheckbooleanSkip ZombieBox components peerDependencies compatibility check, false by default
generatedCodestringAbsolute path to directory that will contain code generated in runtime
templatesArrayDirectories to search for server-side templates for (used in scaffolding)

ProjectConfig

Vital project configuration

KeyTypeDescription
namestringRequired! Project name; Will be used as alias name for all project sources
entrystringRequired! Absolute path to application entry point class file path; Must provide a default export
srcstringRequired! Absolute path to directory with application sources; Will be aliased as project name
diststringAbsolute path to output directory; Build artifacts will be put here

EntityConfig

Additional resources

KeyTypeDescription
namestringEntity name; Not used for any purposes whatsoever
cssArrayFile paths to CSS files to be bundled via PostCSS
externalCssArrayURIs of CSS files to be included as link references
modulesArrayFile paths to JS module files to be compiled
inlineScriptsArrayFile paths to JS scripts to be inlined into html via <script> tags
externalScriptsArrayURIs of JS scripts to be included as link references
externsArrayFile paths to GCC externs
staticObjectMap of extra static files to be included into build; Key: web path, value: file system path
aliasesObjectMap of modules aliases; Key: alias name, value: File system path to its root

PostCSSConfig

Configures CSS files processing and bundling

KeyTypeDescription
importEntryPointsArrayCSS @import entry point, if not set imports will not be processed
presetEnvObjectpostcss-preset-env options
filePluginsArrayAny additional plugin instances that will be run against each file. Also run by dev server.
bundlePluginsArrayAny additional plugin instances that will be run against resulting CSS bundle. Not run by dev server
urlObjectpostcss-url options
cssoObjectCSSO optimizer options

DevServerConfig

Development server options

KeyTypeDescription
portnumberHTTP port
proxyObjectMap of urls to proxy
enableRawProxybooleanEnables proxy at /proxy?url=
backdoorstringPath to a JS module file that will be include in dev server only

BuildOptions

Build options

KeyTypeDescription
inlineCSSbooleanInline bundled CSS code into index.html body
inlineJSbooleanInline bundled JS code into index.html body