webdevlabs/webphpack

simple php alternative to webpack for automatic concatenation of multiple JavaScript and CSS files into single files

Installs: 27

Dependents: 0

Suggesters: 0

Security: 0

Stars: 10

Watchers: 1

Forks: 2

Open Issues: 0

Type:package

pkg:composer/webdevlabs/webphpack

1.2.4 2018-02-16 17:29 UTC

This package is not auto-updated.

Last update: 2025-09-28 10:16:22 UTC


README

WebPHPack is a simple php alternative to webpack for automatic concatenation of multiple JavaScript and CSS files into single files.

This library replaces the style/script tags from the input html source code and returns plain html code ready for output. Loading is done asynchronously for both javascript/css.

Added HTTP2 Push support.

Usage

$webphpack = new WebPHPack($htmlsource);
$webphpack->caching = true;
$webphpack->httpush = true;
$webphpack->combineJS();
$webphpack->combineCSS();
$webphpack->output();

or nested

$webphpack = new WebPHPack($htmlsource);
$newHTMLsource = $webphpack->combineJS()->combineCSS()->output();