Skip to content

Commit 8aec6a0

Browse files
committed
refactor compare ref usage
1 parent 260bd8c commit 8aec6a0

File tree

4 files changed

+10
-9
lines changed

4 files changed

+10
-9
lines changed

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ comparisons with the help of dedicated console commands.
1717
- document, dom-elements and other non-serializable objects are filtered-out from the results
1818
- self recurring references displayed only once, the rest of occurrences are filtered-out
1919
- basic integration with search functionality within devtools
20+
- if search query contains upper-case letter - the search will be case-sensitive
2021

2122
### Limitations and workarounds
2223

@@ -48,13 +49,13 @@ console.diffPush(Date.now());
4849
console.diff(Date.now());
4950
```
5051

51-
- **console.diffLeft(left)** - update the old value
52+
- **console.diffLeft(left)** - update the old value only
5253

5354
```javascript
5455
console.diffLeft(Date.now());
5556
```
5657

57-
- **console.diffRight(right)** - update the new value
58+
- **console.diffRight(right)** - update the new value only
5859

5960
```javascript
6061
console.diffRight(Date.now());
@@ -82,7 +83,6 @@ with a single argument, that will shift objects from right to left, showing diff
8283
- reflects result of last compare request
8384
- listens on `jsdiff-devtools-to-panel-compare` requests
8485
- listens on `jsdiff-devtools-to-panel-search` and tries to find query in DOM
85-
- if search query contains upper-case letter - the search will be case-sensitive
8686

8787
### Screenshot
8888

manifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"description": "Compare in-memory objects and see the result inside devtools panel with a set of console.diff functions.",
44
"version": "3.0.0",
55
"manifest_version": 3,
6-
"minimum_chrome_version": "64.0",
6+
"minimum_chrome_version": "66.0",
77
"devtools_page": "src/jsdiff-devtools.html",
88
"icons": {
99
"28": "src/img/panel-icon28.png",

src/js/bundle/jsdiff-panel.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/js/view/panel.vue

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -159,10 +159,11 @@ function $_restartLastUpdated() {
159159
}
160160
161161
function $_onDiffRequest({ left, right, timestamp }: ICompareState) {
162-
// console.log('$_onDiffRequest');
163-
compare.value.left = left;
164-
compare.value.right = right;
165-
compare.value.timestamp = timestamp || Date.now();
162+
compare.value = {
163+
left,
164+
right,
165+
timestamp: timestamp || Date.now(),
166+
};
166167
167168
$_restartLastUpdated();
168169
postDiffRender(deltaEl.value);

0 commit comments

Comments
 (0)