---
# System prepended metadata

title: "\U0001F3C5 Day 44"
tags: [Vue 直播班 - 2022 春季班]

---

---
tags: Vue 直播班 - 2022 春季班
---

# 🏅 Day 44
###### tags: `Vue 直播班 - 2022 春季班`

題目 (請將答案貼上 CodePen)
---
操作 [這個模板](https://codepen.io/rider159159/pen/ExWORqq)，執行以下要求 (只能操作 JS 的部分):

> provide 跨層級通訊
> - 使用 provide 方法，將 cash (1000) 傳送給 ming 元件，但不要讓 ming-mom 元件收到，cash 的值。
> - 提示一: app 為第一層、ming-mom 為第二層、ming 為第三層。
> - 提示二: 請勿使用 props 、 mitt 方法
> - 實際狀況如圖:
> ![](https://i.imgur.com/yxavr9V.png)



 參考: https://courses.hexschool.com/courses/vue-20212/lectures/35988941

回報流程
---
請同學依照下圖教學觀看解答、回報答案:

![](https://i.imgur.com/QtL8zEW.png)

回報格式如下圖，請在「回報區」使用註解回報答案 (為了統計人數，請同學依序加上「報數」)

![](https://i.imgur.com/L7kyew8.png)

<!-- 解答

const ming = {
  template: `<div>
   小明拿到了 {{ this.cash }} 為零用錢
  </div>`,
  inject:['cash'],
} 
 
const app = Vue.createApp({
  data() {
    return {
      cash:1000,
    }
  },
  provide(){
    return{
      cash:this.cash,
    }
  },
})
 
-->

回報區
---
| 報數 |組別/名字  | codepen / 其他回饋    | 
|:--------:| -------- | -------- | 
| 1 | Larry | https://codepen.io/larrylinr5/pen/jOaXamZ?editors=1111 |
| 2 | Bruno Yu | https://codepen.io/bruno-yu/pen/mdqaqBr |
| 3 | CloThEs |  https://codepen.io/bogwdnxx-the-sans/pen/MWOZOeG |
| 4 | Iris Huang | https://codepen.io/ythuang/pen/abVPVGe |
| 5 | 肉鬆 | https://codepen.io/klrkicog/pen/dyZwZVo?editors=1010 |
| 6 | Jason Chen | https://codepen.io/jason60810/pen/yLPGPZG |
| 7 | Empty Wu | https://codepen.io/emptywu/pen/NWweXge |
| 8 | Gill | https://codepen.io/Gill-Chin/pen/LYOMeLW?editors=1010 |
| 9 | Arista | https://codepen.io/arista-hsieh/pen/NWweXJZ |
| 10| YC | https://codepen.io/YCLu/pen/ExbGoJW |
|11| Sheep | https://codepen.io/SheepNDW/pen/PoOXQOY | 
| 12 | Yunei | https://codepen.io/Yunei/pen/wvPRjYN |
|13|andersonshen| https://codepen.io/luxyenni-the-bold/pen/LYOMmoO |
|14|Henry Wu|https://codepen.io/dkcmlaww-the-flexboxer/pen/dyZwKRg |
|15|Rick Tzeng|https://codepen.io/rick917jp6/pen/bGYOmjE |
|16|shio|https://codepen.io/shioyen/pen/ExbGroo |
|17|我是泇吟|https://codepen.io/kljuqbxs/pen/eYebxEW |
|18|Charlotte Lee|https://codepen.io/charlotte-lee/pen/rNYoKoJ |
|19|陳暐中|https://codepen.io/wei-z/pen/VwrqNzW?editors=1010|
|20|咖咖|https://codepen.io/gon790219/pen/mdqagRq|
|21|Bonnie |https://codepen.io/bonnieli1414/pen/yLPGrzd?editors=1010 |
|22|POPEYE |https://codepen.io/popeye_ux/pen/RwjvKdG|
|23|kk|https://codepen.io/potatokaka/pen/jOadBWv?editors=1010|
|24|Jasper|https://codepen.io/li-jasper/pen/MWOxgre |
|25|ZY Hsu|https://codepen.io/zihyin/pen/bGYZGLg?editors=1010 |
|26| Karen Huang | https://codepen.io/Coding_Snorlax/pen/qBVvEOB |
|27| mei | https://codepen.io/Shila-Chen/pen/JjOzOmz |
|28|Otis|https://codepen.io/humming74/pen/WNXmdrd?editors=1010|
| 29 | Wenfish | https://codepen.io/wenfisht/pen/gOXJMMq |
| 30 | 紙飛機 | https://codepen.io/paperplanea/pen/zYpYqZa?editors=1010 |
| 31 | sihle | https://codepen.io/bugbug777/pen/PoEomGw |
|32|Gui|https://codepen.io/guitimliu/pen/VwyRoYz
|33|JD孟璁|https://codepen.io/oikdkmxq-the-looper/pen/XWZWaqP |