diff --git a/README.md b/README.md index ee43911..4d3a113 100644 --- a/README.md +++ b/README.md @@ -303,30 +303,23 @@ index 0000001..0ddf2ba #### StimulusJS with TypeScript ```ts -import { Controller } from "@hotwired/stimulus"; +import { Controller } from '@hotwired/stimulus'; -import { - Diff2HtmlUI, - Diff2HtmlUIConfig, -} from "diff2html/lib/ui/js/diff2html-ui-slim.js"; +import { Diff2HtmlUI, Diff2HtmlUIConfig } from 'diff2html/lib/ui/js/diff2html-ui-slim.js'; // Requires `yarn add highlight.js` -import "highlight.js/styles/github.css"; -import "diff2html/bundles/css/diff2html.min.css"; +import 'highlight.js/styles/github.css'; +import 'diff2html/bundles/css/diff2html.min.css'; export default class extends Controller { connect(): void { - const diff2htmlUi = new Diff2HtmlUI( - this.diffElement, - this.unifiedDiff, - this.diffConfiguration - ); + const diff2htmlUi = new Diff2HtmlUI(this.diffElement, this.unifiedDiff, this.diffConfiguration); diff2htmlUi.draw(); } get unifiedDiff(): string { - return this.data.get("unifiedDiff") || ""; + return this.data.get('unifiedDiff') || ''; } get diffElement(): HTMLElement { @@ -336,7 +329,7 @@ export default class extends Controller { get diffConfiguration(): Diff2HtmlUIConfig { return { drawFileList: true, - matching: "lines", + matching: 'lines', }; } } diff --git a/yarn.lock b/yarn.lock index 86a8337..d500be7 100644 --- a/yarn.lock +++ b/yarn.lock @@ -5353,9 +5353,9 @@ no-case@^3.0.4: tslib "^2.0.3" node-fetch@^2.6.0: - version "2.6.5" - resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.6.5.tgz#42735537d7f080a7e5f78b6c549b7146be1742fd" - integrity sha512-mmlIVHJEu5rnIxgEgez6b9GgWXbkZj5YZ7fx+2r94a2E+Uirsp6HsPTPlomfdHtpt/B0cdKviwkoaM6pyvUOpQ== + version "2.6.7" + resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.6.7.tgz#24de9fba827e3b4ae44dc8b20256a379160052ad" + integrity sha512-ZjMPFEfVx5j+y2yF35Kzx5sF7kDzxuDj6ziH4FFbOp87zKDZNx8yExJIb05OGF4Nlt9IHFIMBkRl41VdvcNdbQ== dependencies: whatwg-url "^5.0.0"