Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

365
Views
How to make Vue app in javascript and make it work in html?

Hi I'm trying to make my Vue app in javascript so it isn't in html. Is there any way how to make it work? I tried this:

In HTML:

<script src="https://cdn.jsdelivr.net/npm/vue"></script>
<script src="assets/actions.js" type="text/javascript"></script>

in javascript:

const AppNotes = Vue.createApp({
    data: {
        newFormtext: "",
        contents: [
            {title: "First Title", contents: ["content1", "content2", "content3"]}

        ]
    },
    methods: {
        addNewFormEvent() {
            this.titles.push(this.formtext)
        }
    }
})

AppNotes.mount('#content') 

but it don't work in my html and text is still like {{ content.title }}

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

Here is a basic template of vuejs 2 using html and javascript, without node.

You must call Vue constructor and set the el value to some tag id.

new Vue({
  el: "#notes-app",
  data: {
    counter: 0
  },
  methods: {
    increment() {
      this.counter++;
    }
  }
});
<script src="https://cdnjs.cloudflare.com/ajax/libs/vue/2.5.17/vue.js"></script>
<div id="notes-app">
  {{ counter }}
  <button v-on:click="increment">increment</button>
</div>

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!