Skip to content
This repository was archived by the owner on Mar 11, 2026. It is now read-only.

Use es classes#219

Merged
JustinBeckwith merged 3 commits intogoogleapis:masterfrom
JustinBeckwith:es6
Sep 14, 2018
Merged

Use es classes#219
JustinBeckwith merged 3 commits intogoogleapis:masterfrom
JustinBeckwith:es6

Conversation

@JustinBeckwith
Copy link
Copy Markdown
Contributor

BREAKING CHANGE: This library is now compatible with es module import syntax.

Old Code

const logging = require('@google-cloud/logging')();
// or...
const Logging = require('@google-cloud/logging');
const logging = new Logging();

New Code

const {Logging} = require('@google-cloud/logging');
const logging = new Logging();

@googlebot googlebot added the cla: yes This human has signed the Contributor License Agreement. label Sep 11, 2018
@ghost ghost assigned JustinBeckwith Sep 11, 2018
@codecov
Copy link
Copy Markdown

codecov Bot commented Sep 11, 2018

Codecov Report

Merging #219 into master will not change coverage.
The diff coverage is 100%.

Impacted file tree graph

@@          Coverage Diff          @@
##           master   #219   +/-   ##
=====================================
  Coverage     100%   100%           
=====================================
  Files           5      5           
  Lines         414    370   -44     
=====================================
- Hits          414    370   -44
Impacted Files Coverage Δ
src/metadata.js 100% <100%> (ø) ⬆️
src/sink.js 100% <100%> (ø) ⬆️
src/log.js 100% <100%> (ø) ⬆️
src/index.js 100% <100%> (ø) ⬆️
src/entry.js 100% <100%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 0d25c48...377f263. Read the comment docs.

@stephenplusplus
Copy link
Copy Markdown
Contributor

Tiiiiny coverage loss :\

Comment thread src/index.js Outdated
class Logging {
constructor(options) {
if (!(this instanceof Logging)) {
return new Logging(options);

This comment was marked as spam.

This comment was marked as spam.

@JustinBeckwith
Copy link
Copy Markdown
Contributor Author

gentle nudge @stephenplusplus

@JustinBeckwith JustinBeckwith merged commit 8c05c4a into googleapis:master Sep 14, 2018
@JustinBeckwith JustinBeckwith mentioned this pull request Sep 14, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

cla: yes This human has signed the Contributor License Agreement.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants