-
Notifications
You must be signed in to change notification settings - Fork 664
Closed
Labels
Description
What problem does this feature solve?
renderToString was added in beta.12 , which uses vue-server-renderer.
I don't expect many users will call this method, as it's intended use is for testing server side code. Adding it as a peer dependency will warn users that they need to install it, even though they probably won't use the renderToString
method.
What does the proposed API look like?
- Remove vue-server-renderer as a peer dependency and handle it ourselves, using something like ensureRequire—https://github.com/vuejs/vue-jest/blob/master/lib/compilers/haml-compiler.js#L6. Users will still need to add additional config to webpack, because webpack will try to bundle native node modules in vue-server-renderer.
- Split
@vue/test-utils
, and@vue/server-test-utils
.@vue/test-utils
will expose mount and shallow,@vue/server-test-utils
will exposerenderToString
.
lmiller1990, timoschwarzer, briluu, hirakida, jimmypuckett and 11 moreiraklisg and kdocki