modified: resources/views/components/simple-home.blade.php

modified:   vite.config.js
This commit is contained in:
2026-02-12 14:58:44 +03:30
parent 6c7855cb7d
commit 46168a2cc5
3 changed files with 36 additions and 33 deletions

View File

@@ -6,15 +6,15 @@
class SimpleHome extends Component class SimpleHome extends Component
{ {
public $message = "Hello World!"; public $message = "Hello World!";
public function changeMessage() public function changeMessage()
{ {
$this->message = "Livewire is working!"; $this->message = "Livewire is working! Now hello matin gav khobi?";
} }
public function render() public function render()
{ {
return view('components.simple-home'); return view('components.simple-home');
} }
} }

View File

@@ -1,14 +1,10 @@
<div class="p-8"> <div class="p-8">
<h1 class="text-3xl font-bold text-blue-600">Simple Test</h1> <h1 class="text-3xl font-bold text-blue-600">Simple Test</h1>
<p class="mt-4 text-lg">{{ $message }}</p>
<p class="mt-4 text-lg">{{ $message }}</p> <button wire:click="changeMessage" class="mt-4 bg-blue-500 text-white px-4 py-2 rounded">
Click to Test
<button wire:click="changeMessage" </button>
class="mt-4 bg-blue-500 text-white px-4 py-2 rounded"> <p class="mt-6 text-gray-600">
Click to Test amine gavvvvvvvvvvvv
</button> </p>
</div>
<p class="mt-6 text-gray-600">
If this changes when clicked, Livewire works!
</p>
</div>

View File

@@ -3,16 +3,23 @@ import laravel from 'laravel-vite-plugin';
import tailwindcss from '@tailwindcss/vite'; import tailwindcss from '@tailwindcss/vite';
export default defineConfig({ export default defineConfig({
plugins: [ plugins: [
laravel({ laravel({
input: ['resources/css/app.css', 'resources/js/app.js'], input: ['resources/css/app.css', 'resources/js/app.js'],
refresh: true, refresh: true,
}), }),
tailwindcss(), tailwindcss(),
], ],
server: { server: {
watch: { host: '192.168.1.21',
ignored: ['**/storage/framework/views/**'], port: 5173,
}, strictPort: true,
cors: true,
watch: {
ignored: ['**/storage/framework/views/**'],
}, },
hmr: {
host: '192.168.1.21',
}
},
}); });