Skip to content

Commit 364e645

Browse files
chore: vite integration in root and cleanups done
1 parent add4940 commit 364e645

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

48 files changed

+43
-1758
lines changed

.gitattributes

+10-4
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
1-
* text=auto
2-
*.css linguist-vendored
3-
*.scss linguist-vendored
4-
*.js linguist-vendored
1+
* text=auto eol=lf
2+
3+
*.blade.php diff=html
4+
*.css diff=css
5+
*.html diff=html
6+
*.md diff=markdown
7+
*.php diff=php
8+
9+
/.github export-ignore
510
CHANGELOG.md export-ignore
11+
.styleci.yml export-ignore

.gitignore

+1-1
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ Homestead.yaml
1515
/node_modules
1616
npm-debug.log
1717
package-lock.json
18-
/public/css
18+
/public/css
1919
/public/js
2020
/public/hot
2121
/public/storage

.styleci.yml

+1-5
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,5 @@ php:
55
finder:
66
not-name:
77
- index.php
8-
- server.php
9-
js:
10-
finder:
11-
not-name:
12-
- webpack.mix.js
8+
js: true
139
css: true

package.json

+6-11
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,13 @@
11
{
22
"private": true,
3+
"type": "module",
34
"scripts": {
4-
"dev": "npm run development",
5-
"development": "mix",
6-
"watch": "mix watch",
7-
"watch-poll": "mix watch -- --watch-options-poll=1000",
8-
"hot": "mix watch --hot",
9-
"prod": "npm run production",
10-
"production": "mix --production"
5+
"dev": "vite",
6+
"build": "vite build"
117
},
128
"devDependencies": {
13-
"axios": "^0.21",
14-
"laravel-mix": "^6.0.6",
15-
"lodash": "^4.17.19",
16-
"postcss": "^8.1.14"
9+
"axios": "^1.6.4",
10+
"laravel-vite-plugin": "^1.0.0",
11+
"vite": "^5.0.0"
1712
}
1813
}

resources/js/app.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
require('./bootstrap');
1+
import './bootstrap';

resources/js/bootstrap.js

+11-7
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,11 @@
1-
window._ = require('lodash');
2-
31
/**
42
* We'll load the axios HTTP library which allows us to easily issue requests
53
* to our Laravel back-end. This library automatically handles sending the
64
* CSRF token as a header based on the value of the "XSRF" token cookie.
75
*/
86

9-
window.axios = require('axios');
7+
import axios from 'axios';
8+
window.axios = axios;
109

1110
window.axios.defaults.headers.common['X-Requested-With'] = 'XMLHttpRequest';
1211

@@ -18,11 +17,16 @@ window.axios.defaults.headers.common['X-Requested-With'] = 'XMLHttpRequest';
1817

1918
// import Echo from 'laravel-echo';
2019

21-
// window.Pusher = require('pusher-js');
20+
// import Pusher from 'pusher-js';
21+
// window.Pusher = Pusher;
2222

2323
// window.Echo = new Echo({
2424
// broadcaster: 'pusher',
25-
// key: process.env.MIX_PUSHER_APP_KEY,
26-
// cluster: process.env.MIX_PUSHER_APP_CLUSTER,
27-
// forceTLS: true
25+
// key: import.meta.env.VITE_PUSHER_APP_KEY,
26+
// cluster: import.meta.env.VITE_PUSHER_APP_CLUSTER ?? 'mt1',
27+
// wsHost: import.meta.env.VITE_PUSHER_HOST ? import.meta.env.VITE_PUSHER_HOST : `ws-${import.meta.env.VITE_PUSHER_APP_CLUSTER}.pusher.com`,
28+
// wsPort: import.meta.env.VITE_PUSHER_PORT ?? 80,
29+
// wssPort: import.meta.env.VITE_PUSHER_PORT ?? 443,
30+
// forceTLS: (import.meta.env.VITE_PUSHER_SCHEME ?? 'https') === 'https',
31+
// enabledTransports: ['ws', 'wss'],
2832
// });

resources/views/.gitignore

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
*
2+
!.gitignore

resources/views/errors/401.blade.php

-5
This file was deleted.

resources/views/errors/402.blade.php

-5
This file was deleted.

resources/views/errors/403.blade.php

-5
This file was deleted.

resources/views/errors/404.blade.php

-5
This file was deleted.

resources/views/errors/419.blade.php

-5
This file was deleted.

resources/views/errors/429.blade.php

-5
This file was deleted.

resources/views/errors/500.blade.php

-5
This file was deleted.

resources/views/errors/503.blade.php

-5
This file was deleted.

0 commit comments

Comments
 (0)