Merge pull request #425 from rtfpessoa/dependabot/npm_and_yarn/node-fetch-2.6.7
build(deps): bump node-fetch from 2.6.5 to 2.6.7
This commit is contained in:
commit
4067ecdb92
2 changed files with 10 additions and 17 deletions
21
README.md
21
README.md
|
|
@ -303,30 +303,23 @@ index 0000001..0ddf2ba
|
||||||
#### StimulusJS with TypeScript
|
#### StimulusJS with TypeScript
|
||||||
|
|
||||||
```ts
|
```ts
|
||||||
import { Controller } from "@hotwired/stimulus";
|
import { Controller } from '@hotwired/stimulus';
|
||||||
|
|
||||||
import {
|
import { Diff2HtmlUI, Diff2HtmlUIConfig } from 'diff2html/lib/ui/js/diff2html-ui-slim.js';
|
||||||
Diff2HtmlUI,
|
|
||||||
Diff2HtmlUIConfig,
|
|
||||||
} from "diff2html/lib/ui/js/diff2html-ui-slim.js";
|
|
||||||
|
|
||||||
// Requires `yarn add highlight.js`
|
// Requires `yarn add highlight.js`
|
||||||
import "highlight.js/styles/github.css";
|
import 'highlight.js/styles/github.css';
|
||||||
import "diff2html/bundles/css/diff2html.min.css";
|
import 'diff2html/bundles/css/diff2html.min.css';
|
||||||
|
|
||||||
export default class extends Controller {
|
export default class extends Controller {
|
||||||
connect(): void {
|
connect(): void {
|
||||||
const diff2htmlUi = new Diff2HtmlUI(
|
const diff2htmlUi = new Diff2HtmlUI(this.diffElement, this.unifiedDiff, this.diffConfiguration);
|
||||||
this.diffElement,
|
|
||||||
this.unifiedDiff,
|
|
||||||
this.diffConfiguration
|
|
||||||
);
|
|
||||||
|
|
||||||
diff2htmlUi.draw();
|
diff2htmlUi.draw();
|
||||||
}
|
}
|
||||||
|
|
||||||
get unifiedDiff(): string {
|
get unifiedDiff(): string {
|
||||||
return this.data.get("unifiedDiff") || "";
|
return this.data.get('unifiedDiff') || '';
|
||||||
}
|
}
|
||||||
|
|
||||||
get diffElement(): HTMLElement {
|
get diffElement(): HTMLElement {
|
||||||
|
|
@ -336,7 +329,7 @@ export default class extends Controller {
|
||||||
get diffConfiguration(): Diff2HtmlUIConfig {
|
get diffConfiguration(): Diff2HtmlUIConfig {
|
||||||
return {
|
return {
|
||||||
drawFileList: true,
|
drawFileList: true,
|
||||||
matching: "lines",
|
matching: 'lines',
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -5353,9 +5353,9 @@ no-case@^3.0.4:
|
||||||
tslib "^2.0.3"
|
tslib "^2.0.3"
|
||||||
|
|
||||||
node-fetch@^2.6.0:
|
node-fetch@^2.6.0:
|
||||||
version "2.6.5"
|
version "2.6.7"
|
||||||
resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.6.5.tgz#42735537d7f080a7e5f78b6c549b7146be1742fd"
|
resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.6.7.tgz#24de9fba827e3b4ae44dc8b20256a379160052ad"
|
||||||
integrity sha512-mmlIVHJEu5rnIxgEgez6b9GgWXbkZj5YZ7fx+2r94a2E+Uirsp6HsPTPlomfdHtpt/B0cdKviwkoaM6pyvUOpQ==
|
integrity sha512-ZjMPFEfVx5j+y2yF35Kzx5sF7kDzxuDj6ziH4FFbOp87zKDZNx8yExJIb05OGF4Nlt9IHFIMBkRl41VdvcNdbQ==
|
||||||
dependencies:
|
dependencies:
|
||||||
whatwg-url "^5.0.0"
|
whatwg-url "^5.0.0"
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue