Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

这个项目组件能不能全局引入? #39

Open
kaikaige opened this issue Apr 21, 2017 · 1 comment
Open

这个项目组件能不能全局引入? #39

kaikaige opened this issue Apr 21, 2017 · 1 comment

Comments

@kaikaige
Copy link

用到每个组件都需要单独引入一次,很不方便
如何在main.js引入一次,各个组件都可以使用?

@kaikaige
Copy link
Author

kaikaige commented Apr 21, 2017

能不能不每次都引入一大堆的组件。。。

main.js
import Vum from 'vum'
Vue.use(Vum)

test.vue
<template>
	<page-header>
		<header-title>VUM</header-title>
	</page-header>
</template>

Unknown custom element: <page-header> - did you register the component correctly? For recursive components, make sure to provide the "name" option.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant