メインコンテンツまでスキップ

API

基本的な使い方

import { MLEngine } from 'markuplint';

const file = await MLEngine.toMLFile('./path/to/page.html');

const engine = new MLEngine(file, {
configFile: './path/to/.markuplintrc',
});

engine.on('log', (id, message) => {
console.log(id, message);
});

const result = await engine.exec();

console.log(result.violations);

パッケージ

パッケージNPMプラットフォーム
markuplintnpm versionNode.js
@markuplint/create-rule-helpernpm versionNode.js
@markuplint/html-parsernpm versionユニバーサル
@markuplint/html-specnpm versionユニバーサル
@markuplint/i18nnpm versionユニバーサル
@markuplint/ml-astnpm versionユニバーサル
@markuplint/ml-confignpm versionユニバーサル
@markuplint/ml-corenpm versionユニバーサル
@markuplint/ml-specnpm versionユニバーサル
@markuplint/parser-utilsnpm versionユニバーサル
@markuplint/rulesnpm versionユニバーサル
@markuplint/typesnpm versionユニバーサル