markdown-magic-last-modified
v2.1.0
Published
Print the last modified date using git for a given file
Downloads
347
Maintainers
Readme
Install command plugin
Add install command to markdown files via markdown-magic
Install
npm i markdown-magic markdown-magic-last-modified --save-devAdding the plugin
See example.ts for usage.
import path from 'path';
import { markdownMagic } from 'markdown-magic';
import LASTMODIFIED from './index.ts';
const config = {
matchWord: 'AUTO-GENERATED-CONTENT',
transforms: {
LASTMODIFIED,
},
};
const markdownPath = path.join(import.meta.dirname, 'README.md');
await markdownMagic(markdownPath, config);Usage in markdown
packages/last-modified/README.md last modified Sun Jul 5 09:09:00 2026 +0200
Options
- file (current file by default) - file to get last modified date from (relative to the Markdown file)
