Closed alvarosabu closed 4 years ago
next branch is ready. can you please create the pull ?
@shakee93 done, changed destination branch to next
@shakee93 be aware that the build
is broken:
cross-env NODE_ENV=production webpack --config ./build/webpack.release.js --progress --hide-modules
/Users/alvarosaburido/as/github/as-vue-toasted/node_modules/webpack-cli/bin/cli.js:93
throw err;
^
Error: webpack.optimize.UglifyJsPlugin has been removed, please use config.optimization.minimize instead.
at Object.get [as UglifyJsPlugin] (/Users/alvarosaburido/as/github/as-vue-toasted/node_modules/webpack/lib/webpack.js:189:10)
is it going to be solve in another branch?
Hello,
This PR is meant for migrating the library to be used in Vue 3.x (is in Work in Progress), the PR set to base
master
but it should be aiming to a/next
branch on the base @shakee93 so both2.x
and3.x
solutions coexist in the same repo. If this branch is created I will change the destination of the PRShould close #179
Basic changes:
vue-toasted/index.js
:Now instead of Vue, the
app
instance is passed so it will work with the newcreateApp
, and the global property will be available onthis
by usingapp.config.globalProperties.$toasted
referenceIn Vue 3.x plugins will leverage
provide
andinject
internally and expose a composition function.To do that I add a
useApi.js
for the use of the library along with the Composition API reference:So now, in any setup method or composition function we can do:
To support the last release candidate vue
3.0.0-rc.9
I needed to update several packages from the package.json, this is causing errors in the webpack build process, especially with the uglify plugin:If someone from the core team is available to help me out with this I think is ready to be used (already tested as a submodule in a personal project).
Feel free to contact me directly if needed.
Happy Coding