Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
Kamona-WD committed Apr 4, 2022
1 parent b8312ec commit f98156e
Show file tree
Hide file tree
Showing 17 changed files with 37 additions and 50 deletions.
3 changes: 1 addition & 2 deletions src/Console/InstallCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ protected function installVue()
});

// Composer Packages
$this->requireComposerPackages('inertiajs/inertia-laravel:0.5.4', 'tightenco/ziggy:^1.4');
$this->requireComposerPackages('inertiajs/inertia-laravel:0.5.4', 'laravel/sanctum:^2.8', 'tightenco/ziggy:^1.4');

(new Filesystem)->cleanDirectory(resource_path('views'));

Expand Down Expand Up @@ -203,7 +203,6 @@ protected function installVue()

copy(__DIR__ . '/../../stubs/vue/tailwind.config.js', base_path('tailwind.config.js'));
copy(__DIR__ . '/../../stubs/vue/webpack.mix.js', base_path('webpack.mix.js'));
copy(__DIR__ . '/../../stubs/vue/webpack.config.js', base_path('webpack.config.js'));
copy(__DIR__ . '/../../stubs/vue/jsconfig.json', base_path('jsconfig.json'));
copy(__DIR__ . '/../../stubs/vue/.babelrc', base_path('.babelrc'));

Expand Down
8 changes: 2 additions & 6 deletions stubs/vue/resources/js/Components/ActionMessage.vue
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,6 @@
</div>
</template>

<script>
import { defineComponent } from 'vue'
export default defineComponent({
props: ['on'],
})
<script setup>
defineProps(['on'])
</script>
40 changes: 19 additions & 21 deletions stubs/vue/resources/js/Components/Checkbox.vue
Original file line number Diff line number Diff line change
Expand Up @@ -3,30 +3,28 @@
class="text-purple-500 border-gray-300 rounded focus:border-purple-300 focus:ring focus:ring-purple-500 dark:border-gray-600 dark:bg-dark-eval-1 dark:focus:ring-offset-dark-eval-1">
</template>

<script>
export default {
emits: ['update:checked'],
<script setup>
import { computed } from 'vue';
props: {
checked: {
type: [Array, Boolean],
default: false,
},
value: {
default: null,
},
const emit = defineEmits(['update:checked']);
const props = defineProps({
checked: {
type: [Array, Boolean],
default: false,
},
value: {
default: null,
},
});
computed: {
proxyChecked: {
get() {
return this.checked;
},
const proxyChecked = computed({
get() {
return props.checked;
},
set(val) {
this.$emit("update:checked", val);
},
},
set(val) {
emit("update:checked", val);
},
}
})
</script>
2 changes: 1 addition & 1 deletion stubs/vue/resources/js/Components/DialogModal.vue
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
<script setup>
import Modal from '@/Components/Modal'
const props = defineProps({
defineProps({
show: {
default: false,
},
Expand Down
2 changes: 1 addition & 1 deletion stubs/vue/resources/js/Components/FormSection.vue
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
import { useSlots, computed } from 'vue'
import SectionTitle from '@/Components/SectionTitle'
const emits = defineEmits(['submitted'])
defineEmits(['submitted'])
const slots = useSlots()
Expand Down
2 changes: 1 addition & 1 deletion stubs/vue/resources/js/Components/InputError.vue
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
</template>

<script setup>
const props = defineProps({
defineProps({
message: String
})
</script>
2 changes: 1 addition & 1 deletion stubs/vue/resources/js/Components/Label.vue
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
</template>

<script setup>
const props = defineProps({
defineProps({
value: String
})
</script>
2 changes: 1 addition & 1 deletion stubs/vue/resources/js/Layouts/Authenticated.vue
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ import Navbar from '@/Components/Navbar'
import PageFooter from '@/Components/PageFooter'
import { sidebarState } from '@/Composables'
const props = defineProps({
defineProps({
title: String
})
</script>
2 changes: 1 addition & 1 deletion stubs/vue/resources/js/Layouts/Guest.vue
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ import PageFooter from '@/Components/PageFooter'
import Button from '@/Components/Button'
import { toggleDarkMode, isDark } from '@/Composables'
const props = defineProps({
defineProps({
title: String
})
</script>
2 changes: 1 addition & 1 deletion stubs/vue/resources/js/Pages/Auth/ForgotPassword.vue
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ import Input from '@/Components/Input'
import Label from '@/Components/Label'
import ValidationErrors from '@/Components/ValidationErrors'
const props = defineProps({
defineProps({
status: String
})
Expand Down
2 changes: 1 addition & 1 deletion stubs/vue/resources/js/Pages/Auth/Login.vue
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ import Input from '@/Components/Input'
import Label from '@/Components/Label'
import ValidationErrors from '@/Components/ValidationErrors'
const props = defineProps({
defineProps({
canResetPassword: Boolean,
status: String,
})
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
<script setup>
import { Tab } from '@headlessui/vue'
const props = defineProps({
defineProps({
title: {
type: String,
}
Expand Down
2 changes: 1 addition & 1 deletion stubs/vue/resources/js/Pages/Profile/Show.vue
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ import TwoFactorAuthenticationForm from '@/Pages/Profile/Partials/TwoFactorAuthe
import UpdatePasswordForm from '@/Pages/Profile/Partials/UpdatePasswordForm'
import UpdateProfileInformationForm from '@/Pages/Profile/Partials/UpdateProfileInformationForm'
const props = defineProps({
defineProps({
sessions: {
type: Array,
},
Expand Down
2 changes: 1 addition & 1 deletion stubs/vue/resources/js/Pages/Welcome.vue
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@
<script setup>
import { Head, Link } from '@inertiajs/inertia-vue3';
const props = defineProps({
defineProps({
canLogin: Boolean,
canRegister: Boolean,
laravelVersion: String,
Expand Down
1 change: 1 addition & 0 deletions stubs/vue/resources/views/app.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
<!-- Scripts -->
@routes
<script src="{{ mix('js/app.js') }}" defer></script>
@inertiaHead
</head>
<body class="font-sans antialiased">
@inertia
Expand Down
9 changes: 0 additions & 9 deletions stubs/vue/webpack.config.js

This file was deleted.

4 changes: 3 additions & 1 deletion stubs/vue/webpack.mix.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,9 @@ mix.js('resources/js/app.js', 'public/js')
require('tailwindcss'),
require('autoprefixer'),
])
.webpackConfig(require('./webpack.config'));
.alias({
'@': 'resources/js',
});


if (mix.inProduction()) {
Expand Down

0 comments on commit f98156e

Please sign in to comment.