1

If there is a hello.vue and I want to use it in index.html but there is not vue-cli and nodejs.

I do know how to use vue.js but do not know how to use the vue'scomponent if I have a hello.vue.

Do not I say it clearly? please do not tell me how to thank you.

how to use it?

1 Answer 1

2

Yes. You just need to import Vue from CDN.

For production:

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

For development: (gives you full warnings and debug mode)

<script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>

Then you can just add a script tag and create a Vue instance.

window.app = new Vue({
  el: "#app"
})

For more information visit the official documentation.

Sign up to request clarification or add additional context in comments.

2 Comments

I mean use vue components without cli and nodejs,I do use the vue.js
You can. But its limited. You can just create your components using Vue.component().

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.