37. DefineAsyncComponent | Loading Component dynamically in the Vue Composition API - Vue 3

  Рет қаралды 1,990

Leela Web Dev

Leela Web Dev

Күн бұрын

Пікірлер: 1
@nick066hu
@nick066hu Жыл бұрын
Hi Leela., thank you for the excellent tutorial. I wonder if you could help me out with some clues in the right direction. I am working on a project where I am loading the Admin area component dynamically. Only a few authorized users can view the Admin area, it works ok, it is quite a big component with children, makes a lot of sense to load it only when needed. My backend API will only allow admin operations with the proper authorization (done with JWT tokens). BUT: I wonder if it is possible to allow the Admin component loading only after authorization. How can I prevent any curious unauthorized user to download the Admin component? I guess I would need to change the import function to include the auth headers in the request to the server, and to somehow include Authorization into the server also. (I am using Windows Server IIS, and .NET 7 for the api, I guess I can serve the component itself from the api ro do this, and not from the same folder where the public components are located) I understand that someone being able to download the Admin component alone can not do anything wrong without knowing the auth tokens, but nevertheless I would not want any unauthorized user to be able to download my dynamic component to explore its functions and peek around its code. Thank you for any clues.
兔子姐姐最终逃走了吗?#小丑#兔子警官#家庭
00:58
小蚂蚁和小宇宙
Рет қаралды 14 МЛН
Colorful Pasta Painting for Fun Times! 🍝 🎨
00:29
La La Learn
Рет қаралды 308 МЛН
Cool Parenting Gadget Against Mosquitos! 🦟👶 #gen
00:21
TheSoul Music Family
Рет қаралды 33 МЛН
НИКИТА ПОДСТАВИЛ ДЖОНИ 😡
01:00
HOOOTDOGS
Рет қаралды 3,1 МЛН
This is why you should lazy load routes and components in Vue
5:14
John Komarnicki
Рет қаралды 14 М.
Vue 3 & Composition API - Full Project
1:09:15
Traversy Media
Рет қаралды 144 М.
A Deep Dive Into Async Components In Vue! (Should You Use This?)
13:04
Program With Erik
Рет қаралды 21 М.
An Easy Vue 3 Skeleton Loading Screen with Suspense
8:36
LearnVue
Рет қаралды 40 М.
Dynamic Components in Vue
14:30
Alexander Lichter
Рет қаралды 8 М.
Loading scripts inside Vue components
8:34
cdruc
Рет қаралды 2,8 М.
兔子姐姐最终逃走了吗?#小丑#兔子警官#家庭
00:58
小蚂蚁和小宇宙
Рет қаралды 14 МЛН