vue-cli-plugin-p11n
vue-cli-plugin-p11n copied to clipboard
Dependency was not found ~entry in ./demo/main.js
In demo/main.js there is import App from '~entry'
.
When starting the demo script, it produces an error dependency was not found.
Steps to reproduce:
Create a new project with vue-cli
vue create my-new-project
Add p11n
vue add p11n
and start the demo
yarn demo
Solution: Change '~entry' to './Demo'
In lib/demo/plugin.js there is a webpack config line 11
.set('~entry', path.resolve(path.join(context, './demo', entry)))
Maybe something went wrong there.
It seems that we should run yarn demo Demo.vue
or npx vue-cli-service demo Demo.vue
command vue-cli-service demo
needs entry
option
Am I understanding correctly that to work with npm
the demo
property in package.json
script
ought to look like
"demo": "vue-cli-service demo ./Demo.vue",