The issue is caused due to the library being linked into the example project for development purposes. The manual suggests disabling resolve.symlinks, which fixed the issue. See commit
Reproduction of an issue when using a built Vue library
/tmp/buggy-vue-lib $ yarn install
/tmp/buggy-vue-lib $ yarn build
Creates dist/buggyvuelib.umd.js
/tmp/buggy-vue-lib $ cd example && yarn install
/tmp/buggy-vue-lib/example $ yarn serve
or
/tmp/buggy-vue-lib/example $ yarn build
The first and sometimes second run will cause an error and fail. The project will compile and run successfully after a few retries. In case of yarn serve
, the failed build has to be exited with ^C before trying again.