Skip to content

isVue3 is not defined #50

New issue

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

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

Already on GitHub? # to your account

Open
baybal opened this issue Aug 14, 2020 · 7 comments
Open

isVue3 is not defined #50

baybal opened this issue Aug 14, 2020 · 7 comments

Comments

@baybal
Copy link

baybal commented Aug 14, 2020

Hello,

I have a following issue. Looks to be a trivial one:

📦  Installing vue-cli-plugin-nativescript-vue...

+ vue-cli-plugin-nativescript-vue@0.3.1
updated 1 package and audited 1300 packages in 10.86s

54 packages are looking for funding
  run `npm fund` for details

found 1 high severity vulnerability
  run `npm audit fix` to fix them, or `npm audit` for details
✔  Successfully installed plugin: vue-cli-plugin-nativescript-vue

? Enter a unique application identifier: org.nativescript.application
? Use HTML5 history mode? (Default: hash mode) No
? Is this a brand new project? (Default: Yes) Yes
? Dual Native AND Web development experience or a Native only? (Default: Dual) Dual Native AND Web
? What type of template do you want to start with? (Default: Simple) Nativescript-Vue-Web - The Simple template, but with NS-Vue like syntax for web components

🚀  Invoking generator for vue-cli-plugin-nativescript-vue...
adding to package.json
deleting from package.json
doing template rendering
 ERROR  ReferenceError: ejs:1
 >> 1| <%_ if (isVue3) { _%>
    2| import { createApp } from 'vue'
    3| import App from '~/App.vue';
    4| import { Page, ActionBar, GridLayout, Button, Img, Label } from 'nativescript-vue-web';

isVue3 is not defined
ReferenceError: ejs:1
 >> 1| <%_ if (isVue3) { _%>
    2| import { createApp } from 'vue'
    3| import App from '~/App.vue';
    4| import { Page, ActionBar, GridLayout, Button, Img, Label } from 'nativescript-vue-web';

isVue3 is not defined
    at eval (eval at compile (/usr/lib64/node_modules/@vue/cli/node_modules/ejs/lib/ejs.js:652:12), <anonymous>:10:8)
    at anonymous (/usr/lib64/node_modules/@vue/cli/node_modules/ejs/lib/ejs.js:682:17)
    at Object.exports.render (/usr/lib64/node_modules/@vue/cli/node_modules/ejs/lib/ejs.js:419:37)
    at renderFile (/usr/lib64/node_modules/@vue/cli/lib/GeneratorAPI.js:523:14)
    at /usr/lib64/node_modules/@vue/cli/lib/GeneratorAPI.js:312:27
    at Generator.resolveFiles (/usr/lib64/node_modules/@vue/cli/lib/Generator.js:268:13)
    at processTicksAndRejections (internal/process/task_queues.js:93:5)
    at async Generator.generate (/usr/lib64/node_modules/@vue/cli/lib/Generator.js:175:5)
    at async runGenerator (/usr/lib64/node_modules/@vue/cli/lib/invoke.js:111:3)
    at async invoke (/usr/lib64/node_modules/@vue/cli/lib/invoke.js:92:3)
@jjspscl
Copy link

jjspscl commented Aug 16, 2020

I have the same issue when creating a new nativescript & web shared code application

@jaysonfrazer
Copy link

I have the same issue. Any resolution on this?

@ryanmstokes
Copy link

I also have the same problem!

@Liber7as
Copy link

Liber7as commented Sep 3, 2020

Same issue here! I think it has to do with the @vue/cli version, but downgrading it doesn't seem to work either.

@DxVapor
Copy link

DxVapor commented Sep 3, 2020

Same problem - any direction would be appreciated

@ccg-oharan
Copy link

Same issue here. I also tried downgrading @vue/cli without success.

@micha-cross
Copy link

This is an issue with with 'vue-cli-plugin-nativescript-vue' not being compatible with the newer @vue/cli versions. The plugin extends templates in the cli to scaffold a new app when you add the plugin. However it doesn't include the new 'isVue3' render option that was introduced to the @vue/cli's templates recently.

I have just created a pull request to fix this (which you can view here: #53). In the mean time downgrading @vue/cli version has worked for me. Downgrading to far seems to cause other issues but I have got it to work with cli version 4.0.0

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Development

No branches or pull requests

8 participants