Download the PHP package larsgowebdev/vite-asset-collector-wp without Composer

On this page you can find all versions of the php package larsgowebdev/vite-asset-collector-wp. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package vite-asset-collector-wp

Vite Asset Collector for WordPress

A WordPress Must-Use Plugin that seamlessly integrates Vite.js with WordPress themes, with live reload support for development and optimized asset loading for production.

This is heavily inspired by vite-asset-collector for TYPO3, which made this project possible.

Features

Requirements

Recommendations for local Development

Installation

As WordPress(Bedrock) dependency

In a composer based setup with Bedrock, this plugin will be automatically symlinked into your web/app/mu-plugins directory, and become available in your WP.

Configuration

Environment Variables

Create a .env file in your WordPress root directory with the following variables:

Configuration requires an .env file based configuration, based on roots/wp-config and oscarotero/env. It should be required by default in a Bedrock project.

Theme Integration

In your theme's functions.php:

Vite Configuration

Example vite.config.js:

Usage

Development Mode

  1. Start your Vite dev server:

  2. The plugin will automatically detect development mode and inject HMR scripts.

Production Mode

  1. Build your assets:

  2. The plugin will automatically load optimized assets from the manifest file.

Enabling file watchers in Vite

To enable watching files for changes and live reloading in your dev environment, you can add a little Vite Plugin:

Enable DDEV Vite-Serve

The ddev-viteserve plugin integrates your Vite dev-server into your environment. Simply install it like this and restart your box:

Then you can run your dev server like this:

And to stop it:

Most importantly, the viteserve plugin sets the port it uses as environment variable:

Credits

This WordPress plugin is an adaptation of the "Vite Asset Collector" extension for TYPO3 CMS, originally created by Simon Praetorius. The original project can be found at:

We thank the original author and contributors for their work, which served as the foundation for this WordPress adaptation.

License

This project is licensed under the GNU General Public License v2.0 - see the LICENSE file for details.

This software is partly derived from "Vite Asset Collector" for TYPO3, which is also licensed under GPL-2.0. As per the GPL-2.0 terms, this derivative work maintains the same license.


All versions of vite-asset-collector-wp with dependencies

PHP Build Version
Package Version
Requires php Version >=8.1
roots/wp-config Version >=1.0.0 <=1.1.0
oscarotero/env Version ^2.1
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package larsgowebdev/vite-asset-collector-wp contains the following files

Loading the files please wait ....