Skip to content

Commit 3c264d6

Browse files
committed
fix: removed console.log messages; updated README
1 parent 5a46c2d commit 3c264d6

File tree

3 files changed

+0
-7
lines changed

3 files changed

+0
-7
lines changed

README.md

-3
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,6 @@ import { applyPolyfill, ReflowStrategy } from 'custom-elements-hmr-polyfill';
2626
applyPolyfill();
2727
```
2828

29-
As you can see, the `autoReflow` can be buffered as well by setting `reflowBufferMs` in milliseconds.
30-
The idea behind this is to limit the amount of DOM traversals and reflows when multiple re-definitions happen in a short timeframe (typical HMR use-case).
31-
3229
### Configure buffering to limit the amount of re-rendering
3330

3431
```ts

src/package/polyfill/createHookElementChangeListener.ts

-2
Original file line numberDiff line numberDiff line change
@@ -26,12 +26,10 @@ export const createHookElementChangeListener = (
2626
setTimeout(() => {
2727
switch (reflowStrategy) {
2828
case ReflowStrategy.REPLACE_BY_CLONE:
29-
console.log('replace');
3029
replaceByClone(elementsChanged);
3130
break;
3231

3332
case ReflowStrategy.RERENDER_INNER_HTML:
34-
console.log('inner');
3533
rerenderInnerHTML();
3634
break;
3735
}

src/package/reflow-strategy/replaceByClone.ts

-2
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,6 @@ const visit = (node: Node, elementNames?: Array<string> | undefined) => {
1414
// - element name filter matches childNode's element name
1515
if (!elementNames || elementNames.indexOf(childNode.nodeName.toUpperCase()) > -1) {
1616
recreateNode(childNode);
17-
18-
console.log('node re-creation for', childNode.nodeName, childNode);
1917
recreatedNode = true;
2018
}
2119

0 commit comments

Comments
 (0)