Skip to content

Commit 5b496da

Browse files
committed
Remove ancient undocument support for listItemIndent: 1
1 parent 2fcac46 commit 5b496da

File tree

2 files changed

+0
-28
lines changed

2 files changed

+0
-28
lines changed

lib/util/check-list-item-indent.js

-6
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,6 @@
1010
export function checkListItemIndent(state) {
1111
const style = state.options.listItemIndent || 'tab'
1212

13-
// To do: remove in a major.
14-
// @ts-expect-error: deprecated.
15-
if (style === 1 || style === '1') {
16-
return 'one'
17-
}
18-
1913
if (style !== 'tab' && style !== 'one' && style !== 'mixed') {
2014
throw new Error(
2115
'Cannot serialize items with `' +

test/index.js

-22
Original file line numberDiff line numberDiff line change
@@ -3249,28 +3249,6 @@ test('listItem', async function (t) {
32493249
}
32503250
)
32513251

3252-
await t.test(
3253-
'should use one space after the bullet for `listItemIndent: "1"` (deprecated)',
3254-
async function () {
3255-
assert.equal(
3256-
to(
3257-
{
3258-
type: 'listItem',
3259-
children: [
3260-
{type: 'paragraph', children: [{type: 'text', value: 'a'}]},
3261-
{type: 'thematicBreak'}
3262-
]
3263-
},
3264-
{
3265-
// @ts-expect-error: check how the runtime handles `listItemIdent` being wrong.
3266-
listItemIndent: '1'
3267-
}
3268-
),
3269-
'* a\n\n ***\n'
3270-
)
3271-
}
3272-
)
3273-
32743252
await t.test(
32753253
'should use one space after the bullet for `listItemIndent: "mixed"`, when the item is not spread',
32763254
async function () {

0 commit comments

Comments
 (0)