Replace Webpack Encore by Vite

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
julielenaertsandClaude Opus 5.5 committed 2026-11-23 15:22:22 +01:00
1 parent 69cd19b932
commit 3926b26ae7
10 files changed
+14639 -31

No files matched your search

+1
View File
@@ -13,6 +13,7 @@ docker/
/node_modules/
/public/build/
npm-debug.log
/yarn.lock
###< node / vite build ###
###> lexik/jwt-authentication-bundle ###
+1 -1
View File
@@ -1 +1 @@
20
24
-7
View File
@@ -1,7 +0,0 @@
import SwaggerUI from 'swagger-ui';
import 'swagger-ui/dist/swagger-ui.css';
SwaggerUI({
url: '/_dev/specs.yaml',
dom_id: '#swag'
})
+10
View File
@@ -0,0 +1,10 @@
pentatrion_vite:
default_config: chill
configs:
# assets of the chill bundles
chill:
build_directory: build
when@prod:
pentatrion_vite:
cache: true
+10
View File
@@ -0,0 +1,10 @@
when@dev:
swagger_ui:
path: /_dev/swagger
controller: Chill\MainBundle\Controller\Dev\SwaggerController::index
swagger_specs:
path: /_dev/specs/{filename}
controller: Chill\MainBundle\Controller\Dev\SwaggerController::spec
requirements:
filename: '[a-zA-Z0-9_-]+\.yaml'
+9
View File
@@ -0,0 +1,9 @@
when@dev:
_pentatrion_vite:
prefix: /build
resource: "@PentatrionViteBundle/Resources/config/routing.yaml"
_profiler_vite:
path: /_profiler/vite
defaults:
_controller: Pentatrion\ViteBundle\Controller\ProfilerController::info
+14558
View File
File diff suppressed because it is too large. Load diff
+12 -11
View File
@@ -1,20 +1,21 @@
{
"workspaces": [
"vendor/chill-project/chill-bundles"
],
"private": true,
"dependencies": {
"@chill-project/chill-bundles": "file:vendor/chill-project/chill-bundles"
},
"devDependencies": {
"@symfony/ux-translator": "file:vendor/symfony/ux-translator/assets",
"bootstrap": "5.2.3",
"intl-messageformat": "^10.5.11"
"@vitejs/plugin-vue": "^6.0.9",
"intl-messageformat": "^10.5.11",
"sass": "^1.89.0",
"typescript": "^5.6.3",
"vite": "^8.3.0",
"vite-plugin-symfony": "^8.2.4"
},
"scripts": {
"specs-build": "yaml-merge vendor/chill-project/chill-bundles/src/Bundle/ChillMainBundle/chill.api.specs.yaml vendor/chill-project/chill-bundles/src/Bundle/ChillPersonBundle/chill.api.specs.yaml vendor/chill-project/chill-bundles/src/Bundle/ChillCalendarBundle/chill.api.specs.yaml vendor/chill-project/chill-bundles/src/Bundle/ChillThirdPartyBundle/chill.api.specs.yaml vendor/chill-project/chill-bundles/src/Bundle/ChillDocStoreBundle/chill.api.specs.yaml> templates/api/specs.yaml",
"specs-validate": "swagger-cli validate templates/api/specs.yaml",
"specs-create-dir": "mkdir -p templates/api",
"specs": "yarn run specs-create-dir && yarn run specs-build && yarn run specs-validate",
"dev": "yarn run encore dev",
"prod": "yarn run encore production"
"dev": "vite",
"build": "vite build",
"prod": "npm run build"
},
"version": "0.0.0"
}
+7 -12
View File
@@ -1,19 +1,14 @@
{
"extends": "./vendor/chill-project/chill-bundles/ts-config-base.json",
"compilerOptions": {
"sourceMap": true
"sourceMap": true,
"baseUrl": "."
},
"includes": [
"./vendor/chill-project/chill-bundles/src/Bundle/**/*.ts",
"./vendor/chill-project/chill-bundles/src/Bundle/**/*.vue",
"include": [
"./assets/**/*.ts",
"./assets/**/*.vue",
"./src/**/*.ts",
"./src/**/*.vue"
],
"exclude": [
"./vendor/chill-project/chill-bundles/tests/*",
"./vendor/chill-project/chill-bundles/docs/*",
"./vendor/chill-project/chill-bundles/assets/translator.ts",
"./vendor/chill-project/chill-bundles/var/*.*"
"./src/**/*.vue",
"./vite.config.ts"
]
}
+31
View File
@@ -0,0 +1,31 @@
import { fileURLToPath, URL } from "node:url";
import { chillVitePreset } from "@chill-project/chill-bundles/vite";
import { defineConfig, mergeConfig } from "vite";
const r = (value: string): string =>
fileURLToPath(new URL(value, import.meta.url));
export default mergeConfig(
chillVitePreset({
// Passed explicitly: this config is ESM, and the preset's default relies on
// `__dirname` being available where it is bundled.
packageRoot: r("vendor/chill-project/chill-bundles"),
outputPath: "public/build",
publicPath: "/build/",
translationsPath: "var/translations",
}),
defineConfig({
resolve: {
// Chill's assets resolve their imports from Chill's own node_modules; keep
// one copy of the shared runtime rather than one per resolution root.
dedupe: [
"vue",
"pinia",
"vue-i18n",
"intl-messageformat",
"@symfony/ux-translator",
],
},
// this application has no entries of its own: only Chill's are built
}),
);