Can't transpile browser validation like in example for IE11 (i.e. non-modern browsers) #6740
Labels
docs
This issue is due to a mistake or omission in the mongoosejs.com documentation
Milestone
Using:
mongoose 5.2.4
webpack: 4.16.1
webpack-cli: 3.0.8
babel-cli: 6.26.0
babel-preset-es2015: 6.24.1
babel-loader: 7.1.5
node: 8.11
Do you want to request a feature or report a bug?
A Bug
What is the current behavior?
Browser version is not being transpiled to IE11 runnable code. E.g. arrow functions are still in the resulting code.
If the current behavior is a bug, please provide the steps to reproduce.
Example can be checked out here.
https://github.com/mkastner/mk-mongoose-browser
Then run "yarn build" and have a look at file "dist/main.js".
What is the expected behavior?
There should not be (amongst other things e.g. "const") any arrow functions.
Please mention your node.js, mongoose and MongoDB version.
node 8.11 but also node 9.x and 10.x
Addendum
lI finally got it running on ie11. You should definitely also add the .babelrc configuration for those not familiar with webpack/babel in the documentation. Your webpack is not working with ie otherwise for "older browsers" (which is more or less a synonym for ie).
But now the validator code adds 1MB!!! to my webpack code. Why?
The text was updated successfully, but these errors were encountered: