In vue.js 2.x I used to simply do
new Vue({
delimiters: ['${', '}'],
...
}
But now it does not seem to work anymore in vue 3.0.2 or 3.1.2 :
const app = Vue.createApp({
delimiters: ['${', '}'],
data() {
return {
display: 'redbox',
}
},
Follinwg the docs, I also tried adding it after constructor like:
const app = Vue.createApp({...});
app.compilerOptions.delimiters = ['${', '}'];
app.mount("#vue-enhanced-page");
But it did not work either and the delimiters are shown literally like ${p.title}. So appreciate your help to fix this.
It may worths noting that I import vue from cdn to my html page:
<script src="https://unpkg.com/vue@3.1.2"></script>