new WpwShebangPlugin(options)
| Name | Type | Description |
|---|---|---|
options | WpwPluginOptions | Plugin options to be applied |
- Source
Extends
Members
(protected) ErrorCode
- Overrides
- Source
(protected) InfoCode
- Overrides
- Source
(protected) Msg
- Overrides
- Source
(protected) MsgCode
- Overrides
- Source
(protected) WarningCode
- Overrides
- Source
(protected) _arr_
Utility shortcut to @spmhome/type-utils/array set of functions
Utility shortcut to @spmhome/type-utils/array set of functions
- Overrides
- Source
(protected) _async_
Utility shortcut to @spmhome/cmn-utils/path set of functions
Utility shortcut to @spmhome/cmn-utils/path set of functions
- Overrides
- Source
(protected) _cmn_
Utility shortcut to @spmhome/cmn-utils/path set of functions
Utility shortcut to @spmhome/cmn-utils/path set of functions
- Overrides
- Source
(protected) _crypto_
Utility shortcut to @spmhome/type-utils/crypto set of functions
Utility shortcut to @spmhome/type-utils/crypto set of functions
- Overrides
- Source
(protected) _date_
Utility shortcut to @spmhome/type-utils/date set of functions
Utility shortcut to @spmhome/type-utils/date set of functions
- Overrides
- Source
(protected) _fs_
Utility shortcut to @spmhome/cmn-utils/fs set of functions
Utility shortcut to @spmhome/cmn-utils/fs set of functions
- Overrides
- Source
(protected) _io_
Utility shortcut to @spmhome/cmn-utils/io set of functions
Utility shortcut to @spmhome/cmn-utils/io set of functions
- Overrides
- Source
(protected) _json_
Utility shortcut to @spmhome/type-utils/json set of functions
Utility shortcut to @spmhome/type-utils/json set of functions
- Overrides
- Source
(protected) _mime_
Utility shortcut to @spmhome/type-utils/mime set of functions
Utility shortcut to @spmhome/type-utils/mime set of functions
- Overrides
- Source
(protected) _node_
Utility shortcut to @spmhome/cmn-utils/node set of functions
Utility shortcut to @spmhome/cmn-utils/node set of functions
- Overrides
- Source
(protected) _num_
Utility shortcut to @spmhome/type-utils/number set of functions
Utility shortcut to @spmhome/type-utils/number set of functions
- Overrides
- Source
(protected) _obj_
Utility shortcut to @spmhome/type-utils/object set of functions
Utility shortcut to @spmhome/type-utils/object set of functions
- Overrides
- Source
(protected) _path_
Utility shortcut to @spmhome/cmn-utils/path set of functions
Utility shortcut to @spmhome/cmn-utils/path set of functions
- Overrides
- Source
(protected) _pms_
Utility shortcut to @spmhome/type-utils/promise set of functions
Utility shortcut to @spmhome/type-utils/promise set of functions
- Overrides
- Source
(protected) _rgx_
Utility shortcut to @spmhome/type-utils/regex set of functions
Utility shortcut to @spmhome/type-utils/regex set of functions
- Overrides
- Source
(protected) _str_
Utility shortcut to @spmhome/type-utils/string set of functions
Utility shortcut to @spmhome/type-utils/string set of functions
- Overrides
- Source
(protected) _ts_
Utility shortcut to @spmhome/cmn-utils/ts set of functions
Utility shortcut to @spmhome/cmn-utils/ts set of functions
- Overrides
- Source
(protected) _types_
Utility shortcut to @spmhome/type-utils/type set of functions
Utility shortcut to @spmhome/type-utils/type set of functions
- Overrides
- Source
(protected) _ver_
Utility shortcut to @spmhome/cmn-utils/version set of functions
Utility shortcut to @spmhome/cmn-utils/version set of functions
- Overrides
- Source
(protected) _www_
Utility shortcut to @spmhome/cmn-utils/fetch set of functions
Utility shortcut to @spmhome/cmn-utils/fetch set of functions
- Overrides
- Source
build :WpwBuild
- Overrides
- Source
buildOptions :WpwBuildOptionsPluginConfig.<"shebang">
- WpwBuildOptionsPluginConfig.<"shebang">
- Overrides
- Source
cacheMap :Record.<WpwBuildOptionsKey, WpwCache>
- Record.<WpwBuildOptionsKey, WpwCache>
- Overrides
- Source
compilation :WebpackCompilation
- WebpackCompilation
- Overrides
- Source
compiler :WebpackCompiler
- WebpackCompiler
- Overrides
- Source
(protected) create
- Overrides
- Source
(protected) ctor
- Overrides
- Source
(protected) disposables :Array.<IDisposable>
- Array.<IDisposable>
- Overrides
- Source
(protected) disposed :boolean
- boolean
- Overrides
- Source
global
- Overrides
- Source
hookCurrent :string|undefined
- string |
undefined
- Overrides
- Source
hookMessages :Record.<string, {start: string, done: string, fail: string}>
- Record.<string, {start: string, done: string, fail: string}>
- Overrides
- Source
(readonly) initMsg :string
- string
- Overrides
- Source
(protected) initialConfig :any
cloned initial configuration object prior to any runtime modifications
.cloned initial configuration object prior to any runtime modifications
- any
- Overrides
- Source
(protected) name :string
module name
.module name
- string
- Overrides
- Source
(protected) slug :string
url/path friendly module name
.url/path friendly module name
- string
- Overrides
- Source
(protected) spmh
Top level export of spmh shared library packages ...{ cls, type, util }...
- Overrides
- Source
(protected) store :WpwCache
- Overrides
- Source
subtype :WpwModuleSubType
- WpwModuleSubType
- Overrides
- Source
(protected) wpc
- Overrides
- Source
Methods
addMessage(info, ifFirstopt) → {SpmhError}
| Name | Type | Attributes | Description |
|---|---|---|---|
info | Partial.<SpmhMessageInfo> | | ||
ifFirst | boolean | | <optional> |
- Overrides
- Source
- Type:
- SpmhError
apply(compiler) → {void|SpmhError}
Main webpack plugin initialization handler, called by webpack runtime to initialize this plugin.
| Name | Type | Description |
|---|---|---|
compiler | WebpackCompiler |
- Overrides
- Source
- Type:
- void |
SpmhError
(async) emitRawAsset(path, tag, emitPathopt, immutableopt, noStatCheckopt) → {Promise.<string>}
| Name | Type | Attributes | Description |
|---|---|---|---|
path | string | path to source asset | |
tag | string | assset stats tag | |
emitPath | string | <optional> | relative path emitted to dist, defaults to 'path' relative to ctx dir |
immutable | boolean | <optional> | |
noStatCheck | boolean | <optional> |
- Overrides
- Source
- Type:
- Promise.<string>
exec(command, program, asyncopt, optionsopt) → {WpwExecResultKind.<P>}
| Name | Type | Attributes | Description |
|---|---|---|---|
command | string | ||
program | string | ||
async | P | <optional> | |
options | WpwModuleExecOptions | <optional> |
- Overrides
- Source
- Type:
- WpwExecResultKind.<P>
exec2(async, options) → {WpwExecResultKind.<P>}
| Name | Type | Description |
|---|---|---|
async | P | |
options | WpwExecOptions |
- Overrides
- Source
- Type:
- WpwExecResultKind.<P>
(async) execScriptsAsync(defs, lPad) → {Promise.<({result: WpwExecResult, results: Array.<WpwExecResult>}|void)>}
All of the exec utility functions are executed in the context of a runtime build
instance, i.e.
All of the exec utility functions are executed in the context of a runtime build
instance, i.e. 'this' is of type InstanceType
| Name | Type | Description |
|---|---|---|
defs | WpwPluginConfigRunScripts | | |
lPad | string |
- Since
- 1.6.0
- Overrides
- Source
- Type:
- Promise.<({result: WpwExecResult, results: Array.<WpwExecResult>}|void)>
execScriptsSync(scriptDef, lPad) → {Object|void}
All of the exec utility functions are executed in the context of a runtime plugin
instance, i.e.
All of the exec utility functions are executed in the context of a runtime plugin
instance, i.e. 'this' is of type InstanceType<WpwPlugin|WpwTaskPlugin>
| Name | Type | Default | Description |
|---|---|---|---|
scriptDef | WpwPluginConfigRunScripts | ||
lPad | string |
- Since
- 1.6.0
- Overrides
- Source
- Type:
- Object |
void
fileNameStrip(file, rmvExtopt) → {string}
| Name | Type | Attributes | Description |
|---|---|---|---|
file | string | ||
rmvExt | boolean | <optional> | remove file extension |
- Overrides
- Source
- Type:
- string
(protected) getErrorMessageCfg(message, codeopt, exceptionopt) → {WpwBaseMessageInfo}
| Name | Type | Attributes | Description |
|---|---|---|---|
message | string | ||
code | SpmhMessageCode | | <optional> | |
exception | SpmhError | | <optional> |
- Overrides
- Source
- Type:
- WpwBaseMessageInfo
getStore(moduleKeyopt) → {WpwCache}
| Name | Type | Attributes | Description |
|---|---|---|---|
moduleKey | WpwBuildOptionsKey | <optional> |
- Overrides
- Source
- Type:
- WpwCache
(abstract, protected) getVendorPlugin(_compiler, _applyFirstopt) → {WebpackPluginInstance|Array.<WebpackPluginInstanceOrUndef>}
| Name | Type | Attributes | Description |
|---|---|---|---|
_compiler | WebpackCompiler | ||
_applyFirst | boolean | <optional> |
- Overrides
- Source
- Type:
- WebpackPluginInstance |
Array.<WebpackPluginInstanceOrUndef>
hashLength() → {number}
- Since
- 1.10.1
- Overrides
- Source
- Type:
- number
hookdone(msgopt, rtnopt) → {T}
| Name | Type | Attributes | Description |
|---|---|---|---|
msg | string | | <optional> | |
rtn | T | <optional> |
- Since
- 1.11.0
- Overrides
- Source
- Type:
- T
hookstart(msgopt, writePluginOptsopt) → {WpwLogger}
| Name | Type | Attributes | Description |
|---|---|---|---|
msg | string | | <optional> | |
writePluginOpts | boolean | <optional> |
- Since
- 1.11.0
- Overrides
- Source
- Type:
- WpwLogger
(protected) invalidHookConfig(hookName, hookType, configDsc) → {SpmhMessage}
| Name | Type | Default | Description |
|---|---|---|---|
hookName | string | ||
hookType | "compiler" | | compilation | |
configDsc | string | async/sync |
- Overrides
- Source
- Type:
- SpmhMessage
isAsyncHook(hook)
| Name | Type | Description |
|---|---|---|
hook | any |
- Overrides
- Source
(protected) isCompilationHook(hook)
| Name | Type | Description |
|---|---|---|
hook | any |
- Overrides
- Source
(protected) isOutputAsset(name, isEntryopt, chkDbgopt, chkExtopt, chkHashedopt, noCacheGrpopt) → {boolean}
| Name | Type | Attributes | Description |
|---|---|---|---|
name | string | ||
isEntry | boolean | <optional> | |
chkDbg | boolean | <optional> | |
chkExt | boolean | <optional> | include file extension in comparisons, defaults to |
chkHashed | boolean | <optional> | |
noCacheGrp | boolean | <optional> |
- Overrides
- Source
boolean
- Type:
- boolean
(protected) isSyncHook(hook, strictopt)
| Name | Type | Attributes | Description |
|---|---|---|---|
hook | any | ||
strict | boolean | <optional> |
- Overrides
- Source
(protected) isTapableHook(hook) → {boolean}
| Name | Type | Description |
|---|---|---|
hook | WpwWebpackCompilerHook | |
- Overrides
- Source
hook is WebpackHook
- Type:
- boolean
(protected) onApply(_compiler) → {WpwPluginTapOptions.<any, void, false>|undefined}
May be implemented by extending WpwPlugin if internal hooks are to be set up.
All plugins either (1) have internal hooks, (2) wrap a vendor plugin, or (3) both.
| Name | Type | Description |
|---|---|---|
_compiler | WebpackCompiler |
- Overrides
- Source
- Type:
- WpwPluginTapOptions.<any, void, false> |
undefined
outputAssetRegex(chkDbgopt, chkExtopt, chkHashedopt) → {RegExp}
| Name | Type | Attributes | Description |
|---|---|---|---|
chkDbg | boolean | <optional> | |
chkExt | boolean | <optional> | |
chkHashed | boolean | <optional> |
- Overrides
- Source
- Type:
- RegExp
printAssetList(i, pPfx, paths, lPad) → {string}
Prints an array of paths as they are processed, including only a specific # of lines
as determined by the log level verbosity, e.g.
Prints an array of paths as they are processed, including only a specific # of lines
as determined by the log level verbosity, e.g. log level 2 will print only the first 8
assets fo,lowed by a generalized message "+ ... additional assets"
| Name | Type | Default | Description |
|---|---|---|---|
i | number | | 0-based index of current asset in the array parameter 'paths' | |
pPfx | string | asset path type / value prefix | |
paths | Array.<string> | array of abs paths indexed by parameter 'i' | |
lPad | string |
- Overrides
- Source
- Type:
- string
(protected) tapCompilationHooks(optionsArray)
| Name | Type | Description |
|---|---|---|
optionsArray | Array.<WpwPluginCompilationTapOptionsPair.<any, any, boolean>> |
- Overrides
- Source