Skip to content

Commit 881646e

Browse files
committed
chore(deps): update dependency js-beautify to v1.14.9
The PR introducing a new option to _not_ inline custom elements has been merged and released, allowing us to use the new version of js-beautify without introducing a breaking change. See #1834 for context
1 parent 5426ca2 commit 881646e

File tree

4 files changed

+47
-48
lines changed

4 files changed

+47
-48
lines changed

.github/renovate.json5

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,6 @@
55
"prConcurrentLimit": 1,
66
// auto-merge if build is OK
77
"automerge": true,
8-
// ignore js-beautify updates until https://github.com/vuejs/test-utils/pull/1834 is resolved
9-
"ignoreDeps": ["js-beautify"],
108
"packageRules": [
119
// group vitest packages update
1210
{

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
"dist/index.d.ts"
2323
],
2424
"dependencies": {
25-
"js-beautify": "1.14.6",
25+
"js-beautify": "1.14.9",
2626
"vue-component-type-helpers": "1.8.4"
2727
},
2828
"devDependencies": {

pnpm-lock.yaml

Lines changed: 41 additions & 42 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/baseWrapper.ts

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ import { isElement } from './utils/isElement'
2929
import type { DOMWrapper } from './domWrapper'
3030
import { createDOMWrapper, createVueWrapper } from './wrapperFactory'
3131
import { stringifyNode } from './utils/stringifyNode'
32-
import beautify from 'js-beautify'
32+
import beautify, { HTMLBeautifyOptions } from 'js-beautify'
3333

3434
export default abstract class BaseWrapper<ElementType extends Node>
3535
implements WrapperLike
@@ -226,8 +226,10 @@ export default abstract class BaseWrapper<ElementType extends Node>
226226
beautify.html(node, {
227227
unformatted: ['code', 'pre', 'em', 'strong', 'span'],
228228
indent_inner_html: true,
229-
indent_size: 2
230-
})
229+
indent_size: 2,
230+
inline_custom_elements: false
231+
// TODO the cast can be removed when @types/js-beautify will be up-to-date
232+
} as HTMLBeautifyOptions)
231233
)
232234
.join('\n')
233235
}

0 commit comments

Comments
 (0)