-
Notifications
You must be signed in to change notification settings - Fork 1.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
docs(reference): updates reference docs for 3.0.0 #1607
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a few comments, looks pretty good otherwise!
|
||
ECMAScript Next (also know as ESNext, ES2015, ES6, and many other names) is the new future of the Javascript language. It introduces fundamental changes in JavaScript while maintaining backward compatibility with ECMAScript 5. | ||
|
||
The MongoDB Node.js driver embraces the new JavaScript version to provide the end user with much improved functionality. We do this primarily by exposing Promises for all `async` methods without breaking backward compatibility with existing code using the driver. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we reword this a little?
The MongoDB Node.js driver embraces modern JavaScript by optionally returning Promises from all async methods.
something like that?
|
||
The MongoDB Node.js driver embraces the new JavaScript version to provide the end user with much improved functionality. We do this primarily by exposing Promises for all `async` methods without breaking backward compatibility with existing code using the driver. | ||
|
||
This section exposes how to use the MongoDB Node.js driver with ESNext6, leveraging all the productivity gains you get from the new Generators. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ESNext6 wut?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also let's not talk about generators :)
var logger = Logger('A', options); | ||
class A { | ||
constructor() { | ||
this.logger = Logger('A'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this is actually required to be new Logger('A')
(see: https://github.com/mongodb-js/mongodb-core/blob/3.0.0/lib/connection/logger.js#L25)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ditto @mbroadst's comments and otherwise looks good 👍
Updating the "Reference" part of the reference docs for 3.0.0