Questions tagged [laravel-vite]

45 questions
1
vote
0 answers

After using vue3-notification in laravel sail and vite, I got "permission denied" on non-existing directory, what can I do?

I'm trying to add this package https://github.com/kyvg/vue3-notification I'm using vue3 with laravel sail and vite, after installing this package, my "sail npm run dev" command prints an error error when starting dev server: Error: EACCES:…
Lamantinoss
  • 159
  • 1
  • 8
1
vote
1 answer

Why moving laravel 9 app under homestead I got many npm errors?

I try to run my laravel 9 app under homestead and entering into homestead box I run composer install and npm install with success. I removed subdirectories node_modules and vendor and cleared I had after working in hosting Kubuntu 20.04) But on…
mstdmstd
  • 2,195
  • 17
  • 63
  • 140
1
vote
0 answers

Laravel Vite configuration for separating assets (CSS and images)

I have one application where I want to separate my asset folders in Vite configuration. This is how my current vite.config.js look like. I want something like import { defineConfig } from 'vite'; import laravel from 'laravel-vite-plugin'; export…
wontone_boys
  • 77
  • 13
1
vote
2 answers

How can I add custom JS file to vite.config.js - Laravel 9?

In prior versions of Laravel, I moved code with custom JS files into webpack.mix.js. Is there a way to make a similar one in Laravel 9, which uses vite.config.js? mix.copy('resources/js/custom-file.js', 'public/js/').version();
Petro Gromovo
  • 1,755
  • 5
  • 33
  • 91
1
vote
0 answers

Laravel Vite build error: 'resolve' is not exported by __vite-browser-externaL

I'm trying to build and version the assets for production in a Laravel project. I'm using laravel-vite-plugin version 0.6.1, node version v16.17.1, npm version 8.19.2. For this, when I run npm run build, I get the following error. > 'resolve' is not…
Tariq Imtinan
  • 114
  • 1
  • 14
0
votes
1 answer

datetimepicker for Laravel Vite Not Working

I have this on my package.json file "moment": "^2.24.0", "eonasdan-bootstrap-datetimepicker": "^4.17.47", On my resolve-alias on my vite.config.js: 'moment': path.resolve(__dirname, 'node_modules/moment'), 'eonasdan-bootstrap-datetimepicker':…
kapitan
  • 2,008
  • 3
  • 20
  • 26
0
votes
1 answer

Remote server + Laravel Vite HMR blank screen

I have an issue working with Laravel 10 and Vite on remote server. I use VS Code and SFTP Extension to sync my project between local and remote server. It works great. My Vite DEV server is also running on remote machine. I edit blade templates from…
Shellai
  • 7
  • 1
  • 4
0
votes
2 answers

@vite( 'resources/css/app.css' 'resources/js/app.js' ) is not working with laravel 9, vite 4.0.0

In Laravel 9 app, I installed Laravel auth (with Jetstreem livewire & vite-4.0.0) using the following commands: composer require laravel/jetstream php artisan jetstream:install livewire php artisan migrate npm install npm run dev npm run build In my…
0
votes
0 answers

Unable to locate file in Vite manifest: resources/sass/appff.scss. Laravel:10.6.2, while installing new project with php artisan auth:ui

Why i have this error when i try to run my app in pro mode with laravel 10 while in dev mode it run perfectly: Unable to locate file in Vite manifest: resources/sass/appff.scss. Laravel:10.6.2, while installing new project with php artisan…
0
votes
0 answers

Vite build compiled files based on directories

this is something that I used to do in gulp and webpack but I'm not able to achieve this on vite. I have different themes in different folders like resources/ themes/ theme1/ js/ css/ theme2/ …
Ali Rasheed
  • 2,765
  • 2
  • 18
  • 31
0
votes
2 answers

How to set theme wise folder structure in laravel vite js build

How to set theme wise folder structure in laravel vite js build Below my code working only js folder structure but css file folder structure not working properly. import { defineConfig } from 'vite'; import laravel from 'laravel-vite-plugin'; import…
0
votes
0 answers

issue when compiling with vite

I am using Vite in my laravel project, when I run the command npm run build all of the files are compiled and built in the build directory. my problem is that some of my functions in JS files will be removed during the compiling with vite because…
0
votes
0 answers

Install Tinymce Using Vite In Laravel

how do we install TinyMce using vite in Laravel? i tried changing to laravel mix but for some reason it didn't work at all. so i kinda gave up on that for now. i searched for ways to install TinyMce but i didn't find anything or any instruction on…
zhela
  • 41
  • 6
0
votes
0 answers

Vite, Laravel, and dependencies in package.json not being bundled/served

This question probably boils down to me not fully understanding how vite works, but I've read a bit of the docs and watched a few youtube videos and evidently I'm derpy because I'm not getting it. Issue I get 404 errors on package.json dependencies.…
hyphen
  • 2,368
  • 5
  • 28
  • 59
0
votes
2 answers

How to inject any js file inside head tag in Laravel v9.19 in development server?

I'm using Laravel v9.19 and Vite v4.0.0. When I'm adding config.js file using @vite directive, it is always executing after all the html content is loaded. But, I'm trying to execute config.js file before all the html content is loaded. The purpose…