Composition API RFC Release Note - ChoDragon9/posts GitHub Wiki


title: Composition API RFC ๋ฆด๋ฆฌ์ฆˆ ๋…ธํŠธ ์ •๋ฆฌ sidebar: auto

::: tip @vue/composition-api์˜ ๋ฆด๋ฆฌ์ฆˆ ๋…ธํŠธ๋ฅผ ํ†ตํ•ด ์–ด๋–ค ๋ณ€๊ฒฝ ์‚ฌํ•ญ์ด ์ƒ๊ธธ์ง€ ์˜ˆ์ƒํ•˜๊ธฐ ์œ„ํ•ด ์ •๋ฆฌํ•œ ํฌ์ŠคํŠธ์ž…๋‹ˆ๋‹ค. :::

v0.4.0

  • [๋ฆฌํŒฉํ† ๋ง] ์ด๋ฆ„๋ณ€๊ฒฝ createComponent => defineComponent
  • [๋ผ์ดํ”„์‚ฌ์ดํด] onUnmounted์˜ ํ˜ธ์ถœ ์‹œ์ ์ด destroyed์™€ deactivated => destroyed๋กœ ๋ณ€๊ฒฝ #217

v0.3.3

  • [๋ผ์ดํ”„์‚ฌ์ดํด] onServerPrefetch ์ถ”๊ฐ€
  • [์ปจํ…์ŠคํŠธ] ssrContext ์ถ”๊ฐ€
  • [TypeScript] computed type ์ด์Šˆ ํ•ด๊ฒฐ

v0.3.2

  • [TypeScript] props ์˜ต์…˜ ํƒ€์ž… ์ถ”๋ก  ๊ฐœ์„ 

v0.3.1

  • [Fix] watcher ์ฝœ๋ฐฑ์ด ์ •์ƒ์ ์ธ ์‹œ์ ์— ํ•ด์ œ ์•ˆ๋˜๋Š” ํ˜„์ƒ ํ•ด๊ฒฐ

v0.3.0

  • [TypeScript] TypeScript ํƒ€์ž… ์ •์˜ ๊ฐœ์„ 
  • [์ปจํ…์ŠคํŠธ] context.slots๊ฐ€ render์ „์— ์‚ฌ์šฉํ•  ์ˆ˜ ์—†๋Š” ํ˜„์ƒ ํ•ด๊ฒฐ

v0.2.1

  • [TypeScript] prop ํƒ€์ž…์„ ์ง์ ‘ ์„ ์–ธ ๊ฐ€๋Šฅํ•จ
import { createComponent, createElement as h } from '@vue/composition-api'

interface Props {
  msg: string
}

const MyComponent = createComponent<Props>({
  props: { 
     msg: {}  // required by vue 2 runtime
  },
  setup(props) {
    return () => h('div', props.msg)
  }
})
  • [TypeScript] ref ํƒ€์ž… ์„ ์–ธ
const dateRef = ref<Date>(new Date);

v0.2.0

  • [๋ฆฌํŒฉํ† ๋ง] ์ด๋ฆ„ ๋ณ€๊ฒฝ onBeforeDestroy() => onBeforeUnmount()
  • [๋ผ์ดํ”„์‚ฌ์ดํด] onCreated(), onDestroyed ์ œ๊ฑฐ

v0.1.0

  • RFC๋กœ ๋˜๋ฉด์„œ ํŒจํ‚ค์ง€ ์ด๋ฆ„ ๋ณ€๊ฒฝ๋จ
โš ๏ธ **GitHub.com Fallback** โš ๏ธ