Open Dumorya opened 5 months ago
Hmm. Does the vendor/symfony/ux-chartjs/assets
directory exist that the entry in package.json
is referring to? Ultimately, you're supposed to end up with a node_modules/@symfony/ux-chartjs/
directory with files inside.
There actually is an assets directory with a dist directory and a package.json file inside.
@weaverryan Hi, any chance you have some news about it? :)
Hi @weaverryan , it turns out there is no ux-chartjs directory created in node_modules/@symfony. Do you have any idea why?
Hi @Dumorya !
I used only your composer.json
file to reproduce
composer install
npm install --force
The files are then correctly found in the node_modules/@symfony/ux-charts/dist
directory
➜ ux-npm ls -la node_modules/@symfony/
total 0
drwxr-xr-x 5 simonandre staff 160 20 mar 15:01 .
drwxr-xr-x 450 simonandre staff 14400 20 mar 15:01 ..
drwxr-xr-x 8 simonandre staff 256 20 mar 15:01 stimulus-bridge
lrwxr-xr-x 1 simonandre staff 38 20 mar 15:01 ux-chartjs -> ../../vendor/symfony/ux-chartjs/assets
drwxr-xr-x 9 simonandre staff 288 20 mar 15:01 webpack-encore
➜ ux-npm ls -la node_modules/@symfony/ux-chartjs/dist
total 16
drwxr-xr-x 4 simonandre staff 128 22 fév 13:15 .
drwxr-xr-x 4 simonandre staff 128 22 fév 13:15 ..
-rw-r--r-- 1 simonandre staff 280 22 fév 13:15 controller.d.ts
-rw-r--r-- 1 simonandre staff 1918 22 fév 13:15 controller.js
You may have missed a recipe.
Try to update them with composer recipes
maybe ?
For information that is the content of the generated packages.json
file
{
"devDependencies": {
"@babel/core": "^7.17.0",
"@babel/preset-env": "^7.16.0",
"@hotwired/stimulus": "^3.0.0",
"@symfony/stimulus-bridge": "^3.2.0",
"@symfony/ux-chartjs": "file:vendor/symfony/ux-chartjs/assets",
"@symfony/webpack-encore": "^4.0.0",
"chart.js": "^3.4.1 || ^4.0",
"core-js": "^3.23.0",
"regenerator-runtime": "^0.13.9",
"webpack": "^5.74.0",
"webpack-cli": "^4.10.0",
"webpack-notifier": "^1.15.0"
},
"license": "UNLICENSED",
"private": true,
"scripts": {
"dev-server": "encore dev-server",
"dev": "encore dev",
"watch": "encore dev --watch",
"build": "encore production --progress"
}
}
So maybe the stimulus-bridge version to change ?
Issue
When I run the command line "npm run build", I get the following error:
This package.json file in fact doesn't exist. As recommended, I ran the command line "npm i --force", but it didn't change anything.
Main package.json
Composer.json