MixCompile

 class System\Console\Asset\Mix\MixCompile
extends System\Console\Asset\AssetCompile
implements 
    Symfony\Component\Console\Command\SignalableCommandInterface

Extends

Class Description
AssetCompile

Traits

Trait Description
HandlesCleanup

Console Command Trait that injects cross-platform signal handling to trigger cleanup on exit through the handleCleanup() method on the implementing class.

ProvidesAutocompletion

Console Command Trait that injects cross-platform signal handling to trigger cleanup on exit through the handleCleanup() method on the implementing class.

Properties

protected $configFile : string

Name of config file i.e. mix.webpack.js, vite.config.js

protected static $defaultName : string | null

The default command name for lazy loading.

protected $description : string

The console command description.

protected $replaces : array

List of commands that this command replaces (aliases)

protected $signature : string

The name and signature of this command.

inherited protected $laravel : Winter\Storm\Foundation\Application

Inherited from AssetCompile

inherited protected $packageJson : System\Classes\Asset\PackageJson

Inherited from AssetCompile

PackageJson object holding the contents of the active package.json

inherited protected $watchingFilePath : string

Inherited from AssetCompile

File path being watched, used for cleanup by mix:watch

Methods

public handle () : integer

Call the AssetCompile::compileHandle with the mix type

Returns
integer

protected afterExecution (string $configPath) : void

Remove the temporary mix.webpack.js file

Parameters
Property Description
$configPath
string
Returns
void

protected beforeExecution (string $configPath) : void

Create the temporary mix.webpack.js config file to run webpack with

Parameters
Property Description
$configPath
string
Returns
void

protected createCommand (string $configPath) : array

Create the command array to create a Process object with

Parameters
Property Description
$configPath
string
Returns
array

inherited public __construct ()

Inherited from AssetCompile

Create a new command instance.

Returns
mixed

inherited public alert (string $string, int | string | null $verbosity = null) : void

Inherited from AssetCompile

Write a string in an alert box.

Parameters
Property Description
$string
string
$verbosity
int | string | null
Returns
void

inherited public compileHandle (string $type) : integer

Inherited from AssetCompile
Parameters
Property Description
$type
string
Returns
integer

inherited public complete (Symfony\Component\Console\Completion\CompletionInput $input, Symfony\Component\Console\Completion\CompletionSuggestions $suggestions) : void

Inherited from AssetCompile

Provide autocompletion for this command's input

Parameters
Property Description
$input
Symfony\Component\Console\Completion\CompletionInput
$suggestions
Symfony\Component\Console\Completion\CompletionSuggestions
Returns
void

inherited public error (string $string, int | string | null $verbosity = null) : void

Inherited from AssetCompile

Write a string as error output.

Parameters
Property Description
$string
string
$verbosity
int | string | null
Returns
void

inherited public getSubscribedSignals () : array

Inherited from AssetCompile

Returns the process signals this command listens to

Returns
array

inherited public handleSignal (integer $signal) : void

Inherited from AssetCompile

Handle the provided Unix process signal

Parameters
Property Description
$signal
integer
Returns
void

inherited public handleWindowsSignal (integer $event) : void

Inherited from AssetCompile

Handle the provided Windows process singal.

Parameters
Property Description
$event
integer
Returns
void

inherited public watchHandle (string $type) : integer

Inherited from AssetCompile
Parameters
Property Description
$type
string
Returns
integer

inherited protected executeProcess (string $configPath) : integer

Inherited from AssetCompile

Run the mix command against the provided package

Parameters
Property Description
$configPath
string
Returns
integer

inherited protected getJsConfigPath (string $path) : string

Inherited from AssetCompile

Get the path to the mix.webpack.js file for the provided winter.mix.js file

Parameters
Property Description
$path
string
Returns
string

inherited protected getNpmPackageManifest () : System\Classes\Asset\PackageJson

Inherited from AssetCompile

Read the package.json file for the project, path configurable with the --manifest option

Returns
System\Classes\Asset\PackageJson

inherited protected getPackagePath (string $path) : string

Inherited from AssetCompile

Get the package path for the provided winter.mix.js file

Parameters
Property Description
$path
string
Returns
string

inherited protected isPackageWithinWorkspace (string $mixJsPath) : bool

Inherited from AssetCompile

Check if Mix is able to compile the provided winter.mix.js file

Parameters
Property Description
$mixJsPath
string
Returns
bool

Extended by

Class Description
MixWatch
Copyright © 2024 Winter CMS