listmarkerstyle

package
v0.13.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 8, 2026 License: MIT Imports: 5 Imported by: 0

Documentation

Overview

Package listmarkerstyle implements MDS045, which pins the bullet character for unordered lists. CommonMark accepts `-`, `*`, and `+` interchangeably; this rule requires a single marker (or a rotation by depth) to reduce diff noise and aid visual scanning.

Index

Constants

View Source
const (
	StyleDash     = "dash"
	StyleAsterisk = "asterisk"
	StylePlus     = "plus"
)

Style values for the rule's `style` setting.

Variables

This section is empty.

Functions

This section is empty.

Types

type Rule

type Rule struct {
	Style  string
	Nested []string
}

Rule pins the marker character for unordered lists.

func (*Rule) ApplySettings

func (r *Rule) ApplySettings(s map[string]any) error

ApplySettings implements rule.Configurable.

func (*Rule) Category

func (r *Rule) Category() string

Category implements rule.Rule.

func (*Rule) Check

func (r *Rule) Check(f *lint.File) []lint.Diagnostic

Check implements rule.Rule.

func (*Rule) DefaultSettings

func (r *Rule) DefaultSettings() map[string]any

DefaultSettings implements rule.Configurable.

func (*Rule) EnabledByDefault

func (r *Rule) EnabledByDefault() bool

EnabledByDefault implements rule.Defaultable. The rule is opt-in: users pick a project convention and turn the rule on.

func (*Rule) Fix

func (r *Rule) Fix(f *lint.File) []byte

Fix implements rule.FixableRule.

func (*Rule) ID

func (r *Rule) ID() string

ID implements rule.Rule.

func (*Rule) Name

func (r *Rule) Name() string

Name implements rule.Rule.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL