Skip to content

doc: fix modules.md export example#17579

Closed
apapirovski wants to merge 1 commit into
nodejs:masterfrom
apapirovski:fix-modules-doc-square-example
Closed

doc: fix modules.md export example#17579
apapirovski wants to merge 1 commit into
nodejs:masterfrom
apapirovski:fix-modules-doc-square-example

Conversation

@apapirovski
Copy link
Copy Markdown
Contributor

@apapirovski apapirovski commented Dec 9, 2017

A commit landed recently that made one of our examples no longer execute correctly and instead throw an Error. Updated it to use ES6 and actually make sense.

In hindsight, @Trott's suggestion of adjusting the original wording would've been good but here we are... Since it was a first-time contributor, I would prefer not to revert their changes.

Refs: #17364

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • documentation is changed or added
  • commit message follows commit guidelines
Affected core subsystem(s)

doc

@apapirovski apapirovski added the fast-track PRs that do not need to wait for 72 hours to land. label Dec 9, 2017
@nodejs-github-bot nodejs-github-bot added doc Issues and PRs related to the documentations. module Issues and PRs related to the module subsystem. labels Dec 9, 2017
@apapirovski
Copy link
Copy Markdown
Contributor Author

@apapirovski
Copy link
Copy Markdown
Contributor Author

/cc @Trott could you please have a look since you commented in the original PR? Would like to land this since the current example is broken.

@apapirovski
Copy link
Copy Markdown
Contributor Author

Landed in ec6c063

@apapirovski apapirovski deleted the fix-modules-doc-square-example branch December 12, 2017 00:44
apapirovski added a commit that referenced this pull request Dec 12, 2017
Arrow functions cannot be called with the new keyword,
convert to ES6 classes instead.

PR-URL: #17579
Refs: #17364
Reviewed-By: Rich Trott <rtrott@gmail.com>
MylesBorins pushed a commit that referenced this pull request Dec 12, 2017
Arrow functions cannot be called with the new keyword,
convert to ES6 classes instead.

PR-URL: #17579
Refs: #17364
Reviewed-By: Rich Trott <rtrott@gmail.com>
MylesBorins pushed a commit that referenced this pull request Dec 12, 2017
Arrow functions cannot be called with the new keyword,
convert to ES6 classes instead.

PR-URL: #17579
Refs: #17364
Reviewed-By: Rich Trott <rtrott@gmail.com>
@MylesBorins MylesBorins mentioned this pull request Dec 12, 2017
gibfahn pushed a commit that referenced this pull request Dec 20, 2017
Arrow functions cannot be called with the new keyword,
convert to ES6 classes instead.

PR-URL: #17579
Refs: #17364
Reviewed-By: Rich Trott <rtrott@gmail.com>
@gibfahn gibfahn mentioned this pull request Dec 20, 2017
gibfahn pushed a commit that referenced this pull request Dec 20, 2017
Arrow functions cannot be called with the new keyword,
convert to ES6 classes instead.

PR-URL: #17579
Refs: #17364
Reviewed-By: Rich Trott <rtrott@gmail.com>
@gibfahn gibfahn mentioned this pull request Dec 20, 2017
gibfahn pushed a commit that referenced this pull request Dec 20, 2017
Arrow functions cannot be called with the new keyword,
convert to ES6 classes instead.

PR-URL: #17579
Refs: #17364
Reviewed-By: Rich Trott <rtrott@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

doc Issues and PRs related to the documentations. fast-track PRs that do not need to wait for 72 hours to land. module Issues and PRs related to the module subsystem.

4 participants