minor tweaks to how JS is set up
This commit is contained in:
		| @@ -9,6 +9,12 @@ | |||||||
|         "prod": "npm run production", |         "prod": "npm run production", | ||||||
|         "production": "mix --production" |         "production": "mix --production" | ||||||
|     }, |     }, | ||||||
|  |     "devDependencies": { | ||||||
|  |         "laravel-mix": "^6.0.43", | ||||||
|  |         "postcss": "^8.4.14", | ||||||
|  |         "postcss-import": "^14.1.0", | ||||||
|  |         "vue-loader": "^17.0.0" | ||||||
|  |     }, | ||||||
|     "dependencies": { |     "dependencies": { | ||||||
|         "@inertiajs/inertia": "^0.11.0", |         "@inertiajs/inertia": "^0.11.0", | ||||||
|         "@inertiajs/inertia-vue3": "^0.6.0", |         "@inertiajs/inertia-vue3": "^0.6.0", | ||||||
| @@ -22,13 +28,7 @@ | |||||||
|         "lodash": "^4.17.21", |         "lodash": "^4.17.21", | ||||||
|         "notiwind": "^1.2.5", |         "notiwind": "^1.2.5", | ||||||
|         "tailwindcss": "^3.0.24", |         "tailwindcss": "^3.0.24", | ||||||
|         "tailwindcss-neumorphism": "^0.1.0", |         "tailwindcss-neu": "^0.2.1", | ||||||
|         "vue": "^3.2.36" |         "vue": "^3.2.36" | ||||||
|     }, |  | ||||||
|     "devDependencies": { |  | ||||||
|         "laravel-mix": "^6.0.43", |  | ||||||
|         "postcss": "^8.4.14", |  | ||||||
|         "postcss-import": "^14.1.0", |  | ||||||
|         "vue-loader": "^17.0.0" |  | ||||||
|     } |     } | ||||||
| } | } | ||||||
| @@ -1,14 +1,15 @@ | |||||||
| require("./bootstrap"); | require("./bootstrap"); | ||||||
|  |  | ||||||
| import { createApp, h } from "vue"; | import { createApp, h } from 'vue'; | ||||||
| import { createInertiaApp } from "@inertiajs/inertia-vue3"; | import { createInertiaApp } from '@inertiajs/inertia-vue3'; | ||||||
| import { InertiaProgress } from "@inertiajs/progress"; | import { InertiaProgress } from '@inertiajs/progress'; | ||||||
| import Notifications from "notiwind"; | import { ZiggyVue } from '../../vendor/tightenco/ziggy/dist/vue.m'; | ||||||
|  | import Notifications from 'notiwind'; | ||||||
|  |  | ||||||
| const appName = window.document.getElementsByTagName("title")[0]?.innerText || "Laravel"; | const appName = window.document.getElementsByTagName('title')[0]?.innerText || 'Laravel'; | ||||||
|  |  | ||||||
| window.genUid = function () { | window.genUid = function () { | ||||||
|     return [...Array(16)].map(() => Math.floor(Math.random() * 16).toString(16)).join(""); |     return [...Array(16)].map(() => Math.floor(Math.random() * 16).toString(16)).join(''); | ||||||
| }; | }; | ||||||
|  |  | ||||||
| createInertiaApp({ | createInertiaApp({ | ||||||
| @@ -18,6 +19,7 @@ createInertiaApp({ | |||||||
|         return createApp({ render: () => h(app, props) }) |         return createApp({ render: () => h(app, props) }) | ||||||
|             .use(plugin) |             .use(plugin) | ||||||
|             .use(Notifications) |             .use(Notifications) | ||||||
|  |             .use(ZiggyVue, Ziggy) | ||||||
|             .mixin({ methods: { route } }) |             .mixin({ methods: { route } }) | ||||||
|             .mount(el); |             .mount(el); | ||||||
|     }, |     }, | ||||||
|   | |||||||
							
								
								
									
										6
									
								
								src/resources/js/bootstrap.js
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										6
									
								
								src/resources/js/bootstrap.js
									
									
									
									
										vendored
									
									
								
							| @@ -23,5 +23,9 @@ window.axios.defaults.headers.common['X-Requested-With'] = 'XMLHttpRequest'; | |||||||
| //     broadcaster: 'pusher', | //     broadcaster: 'pusher', | ||||||
| //     key: process.env.MIX_PUSHER_APP_KEY, | //     key: process.env.MIX_PUSHER_APP_KEY, | ||||||
| //     cluster: process.env.MIX_PUSHER_APP_CLUSTER, | //     cluster: process.env.MIX_PUSHER_APP_CLUSTER, | ||||||
| //     forceTLS: true | //     wsHost: import.meta.env.MIX_PUSHER_HOST ?? `ws-${import.meta.env.MIX_PUSHER_CLUSTER}.pusher.com`, | ||||||
|  | //     wsPort: import.meta.env.MIX_PUSHER_PORT ?? 80, | ||||||
|  | //     wssPort: import.meta.env.MIX_PUSHER_PORT ?? 443, | ||||||
|  | //     forceTLS: (import.meta.env.MIX_PUSHER_SCHEME ?? 'https') === 'https', | ||||||
|  | //     enabledTransports: ['ws', 'wss'], | ||||||
| // }); | // }); | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user