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

Help. 请教 vue2 项目中 如何 使用 cdn 引入 art-template 并使用? #636

Open
radiorz opened this issue Mar 22, 2021 · 0 comments

Comments

@radiorz
Copy link

radiorz commented Mar 22, 2021

请问一下 cdn 引入, 使用还需要引入什么么,报错了
报错内容:

ReferenceError: template is not defined

我在vue2 项目的 index.html 中引入了cdn

<script src="https://cdn.jsdelivr.net/npm/[email protected]/index.min.js"></script>

在 methods中使用:

this.$refs.card.append(
  template('art-card', {
    message: '112312323'
  })
)
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