# Assets

# directives

  • 유형: Object

  • 설명:

    컴포넌트 인스턴스에서 사용할 수 있는 디렉티브들의 해시(hash)입니다.

  • 사용방법:

    const app = Vue.createApp({})
    
    app.component('focused-input', {
      directives: {
        focus: {
          mounted(el) {
            el.focus()
          }
        }
      },
      template: ``
    })
    
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
  • 커스텀 디렉티브(Custom Directives)

# components

  • 유형: Object

  • 설명:

    컴포넌트 인스턴스에서 사용할 수 있는 컴포넌트의 해시(hash)입니다.

  • 사용방법:

    const Foo = {
      template: `Foo`
    }
    
    const app = Vue.createApp({
      components: {
        Foo
      },
      template: ``
    })
    
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
  • 컴포넌트(Components)

Deployed on Netlify.
Last updated: 12/19/2020, 10:21:20 PM