Return to homepage

Comments

Davies

Hi, I am having an error when trying to dispatch the csrf-cookie on admin/login page.

unknown action type: login - It is not reading the login action in the store.

  • 1
Reza

HI, what's a bit unusual for me is this uuid thing. I believe you basically use them as you cannot wait for the Primary key "Id" being created, right (otherwise we would auto save on nothing once created)? An alternative would have been to use the id in a "created" hook of Eloquent, however then the slug column must be null. is this the typical way to go Alex?

I might be overthinking this one, but I don't really see a good reason to have an uuid and slug, except of this fallback option you have, when the slug is deleted completely. For instance, in your (excellent) Files Marketplace you also use an identifier, but there you mention to either use a slug or an identifier. Here you are using both.

  • 2
Larry

As a learning exercise, I rewrote everything using script setup.

It was generally pretty straight forward except for the renderless components, which I couldn't quite figure out.

If anyone's done this already, please post in the comments!

  • 1
Phillip

I did the same thing too except for the ResizeComponent. I couldn't get it to work with script setup. I also couldn't get the cookie authentication working so I used token based and it's fantastic. I also refactored the controllers to a single file.

  • 0
Larry

This was awesome

  • 0
Mirakhmad

I think would be better to only import Lodash functions which were required rather than the whole library?

1import debounce from 'lodash/debounce'
2import cloneDeep from 'lodash/cloneDeep'
  • 0
wrends

Is this actually xxs-safe if you allow the client to post html? e.g. a malicious blog moderator / employee could do a lot of harm if he finds out that it is possible to post html as input, can it be saved as markdown instead?

  • 0
Theophilus

Hey Alex, great lessons on Vue and Laravel I must say. Please can you advice on how to run a HTML template (e.g from Themeforest) on a Vue client, while the back-end runs on Laravel. Problem is, the templates come with lots of Javascript libraries already (e.g owl-carousel, waypoint, isotope, slider-revolution, e.t.c). I'll appreciate your help

  • 0
Phillip

There are chances that you don't want the inner data element. In your AppServiceProvider, simply add JsonResource::withoutWrapping(); to the boot method

  • 1
gerah

@Alex Your old editor reads better. This editor is ok but sometimes its hard to follow which file you are on.

  • 0
Shaung

Hello Alex, why using so many controller files. I don't understand.

  • 1
Shaung

If your vue dev tools do not work, use vuedevtool beta version.

  • 0
Rust

Hey Alex, I'm on episode 22 and as I replaced the "slug" to "uuid' I cannot get rid of this error message :

Uncaught (in promise) Error: Missing required param "slug" vue-router.esm-bundler.js:1005

  • 2
Ryan

I had the exact same problem at the end of episode 21. Uncaught (in promise) Error: Missing required param "slug"

Yet in my Edit.vue file I have <router-link class="text-sm font-medium text-gray-800" :to="{name: 'post', params: {slug: post.slug} }"> Preview </router-link>

I can confirm that {{post.slug}} does properly appear on the page. I copied the exact router-link to the admin/posts page, and the link works properly. I took the known good link from the Home.vue file and ended up with the same error.

Here is my github repo on this https://github.com/simpleittools/laravelblogwithvue/tree/master/blog There must be something I am missing on this page, but I cannot find the actual problem. For now I have bypassed it and marked it as a todo.

  • 0
Julia

Hello, have you managed to solve this problem? I have the same problem

  • 0
Ryan

No. I will revisit this soon. I have started on another project. I will loop back around and check quite a few things when I do. If/when I get an answer, I will update it here.

  • 0
Mihai

Just use v-if="post.slug" on the router-link, to be honest I don't know how it's working for him without.

  • 0
Shaung

Why not using only PostController?

  • 1
Jerson

Hi Alex just for to know... What is the vscode theme you're using?

  • 1
Rust

Episode 14 :

The file is not available for download as you said, the login page yes but the other one is not

  • 0
Alex

Just added, thanks for letting me know!

  • 0
Asif

Resource for "Listing posts fro admins" is missing.

  • 0
Alex

Just added :)

  • 0
Shoaib

I think the setup attribute on the script tag is more convinient for vue composition api.

1<script setup>
2//
3</script>
  • 2
Alex

I agree!

  • 0
wandumi

Finally am learning something I wanted so bad between this two tech stack, finally, I can finalize my application

  • 1
Dmitriy

You can use Tailwind's JIT compile mode to reduce CSS file size and increase build speed https://tailwindcss.com/docs/just-in-time-mode

  • 0
Shoaib

we don't need to pull this separately now. All you need to do is just put mode jit in tailwind config.

1module.exports = {
2 mode: 'jit', // <--- See this
3 purge: [],
4 theme: {
5 extend: {},
6 },
7 variants: {
8 extend: {},
9 },
10 plugins: [],
11}
  • 0
Alex

Thanks Dmitriy. Didn't want to go into that here, but a great tip for anyone browsing the comments.

  • 0
Omar

This looks interesting Alex thanks for coming up with this course. I am excited and curious at the same time :) So how many episodes are we expecting in this course, Alex?

  • 0
Alex

There will be just over 30 episodes (estimated, since it's still being recorded).

  • 0
Omar

Great, and thank you

  • 0
sylvain

hi, where is a tha github ?

  • 0
Alex

There's no GitHub link for this, but the source code will be available once the series is complete.

  • 0
Haitham

Thank you, Alex ^_^

Waiting for the rest videos.

  • 2
Dhruv

Thank you Alex very much for this series. Please also add image uploading feature using tiptap editor.

  • 12
Jovani

I swear you can read minds Alex, but thank you!

  • 3