承接 mressex/cubex-vite-plugin 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

mressex/cubex-vite-plugin

最新稳定版本:0.0.10

Composer 安装命令:

composer require mressex/cubex-vite-plugin

包简介

Cubex Plugin for Vite

README 文档

README

Introduction

Vite is a modern frontend tool that delivers an extremely fast development experience. It includes features like lightning-fast cold server start, instant hot module replacement, and optimized builds for production.

This plugin integrates Vite into Cubex to provide a seamless development experience.

This project is a modified version of the CodeIgniter Vite Plugin which in turn is based on the Laravel Vite Plugin

Installation

Install with composer:

composer require mressex/cubex-vite-plugin

Create a vite.config.js file in the root of your project:

// vite.config.js
import { defineConfig } from 'vite';
import cubex from "cubex-vite-plugin";

export default defineConfig({
    plugins: [
        cubex([
            'assets/scss/index.scss',
            'assets/ts/index.ts',
        ]),
    ],
});

Getting Started

  • Install your node dependencies: npm install
  • Start vite server: npm run dev

Add to the Cubex DI, also requires Dispatch to be setup

$cubex->share(Vite::class, $cubex->resolve(Vite::class, $ctx->getProjectRoot()));

Loading Your Scripts and Styles

Register and css or ts files in the vite.config.js file. The plugin will automatically load the files in the development environment and use the production build in the production environment.

pass true if you want to include the Vite client for Hot Mode Reloading

protected function _registerResources(Vite $vite): void
  {
    $vite(['assets/scss/index.scss', 'assets/ts/index.ts'], true);
  }

统计信息

  • 总下载量: 62
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 1
  • 点击次数: 2
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 1
  • Watchers: 1
  • Forks: 0
  • 开发语言: TypeScript

其他信息

  • 授权协议: MIT
  • 更新时间: 2025-01-31

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固