diff --git a/.eslintrc.js b/.eslintrc.js index dc7a922..af7c2f2 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -14,7 +14,7 @@ module.exports = { ], rules: { // VS Code linting will not respect the `.prettierrc` options unless injected here: - 'prettier/prettier': ['warn', prettierrc], + 'prettier/prettier': ['error', prettierrc], '@typescript-eslint/no-var-requires': 'off', '@typescript-eslint/no-explicit-any': 'off', }, diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md deleted file mode 100644 index 4c76c57..0000000 --- a/CONTRIBUTING.md +++ /dev/null @@ -1,47 +0,0 @@ -### Local Development - -This project builds with node version: - - - -~~~~~~~~~~bash -v20.10.0 -~~~~~~~~~~ - - - -After cloning the repository, install dependencies and build the project: - -``` -npm ci -``` - -Build the library and watch for changes: - -``` -npm start -``` - -Link your local copy: - -``` -npm link -``` - -`markdown-inject` commands in any terminal will now run using your local copy. - -### Validation - -This app ships with a local suite of [jest](https://jestjs.io/) tests, [eslint](https://eslint.org/) + [prettier](https://prettier.io/) configurations for code consistency and formatting, and [TypeScript](https://www.typescriptlang.org/) type validation. Each of these features can be validated using... - -```bash -npm test -npm run lint -npm run build -``` - -A `validate` utility script chains these calls together, and is called on every commit. - -```bash -npm run validate -``` diff --git a/README.md b/README.md index daf1f62..5461a8e 100644 --- a/README.md +++ b/README.md @@ -67,9 +67,9 @@ Options: -`markdown-inject` expands a given glob for markdown files. Then it discovers the below `CODEBLOCK` HTML comments within each markdown file, performs the appropriate action (in this case, reading another local file), and writes content back into the markdown file: +`markdown-inject` expands a given glob for markdown files. Then it discovers the below `CODEBLOCK` HTML or MDX comments within each markdown file, performs the appropriate action (in this case, reading another local file), and writes content back into the markdown file: -{/* CODEBLOCK_START_USAGE {"ignore": true} */} + ``` @@ -79,7 +79,7 @@ Options: ``` -{/* CODEBLOCK_START {"value": ".nvmrc"} --> + ~~~~~~~~~~bash File: .nvmrc diff --git a/src/md-inject.ts b/src/md-inject.ts index 3fce94f..62b5291 100644 --- a/src/md-inject.ts +++ b/src/md-inject.ts @@ -114,7 +114,6 @@ const main = async ( groupValue, ]) ) - console.log(matchGroups) try { let inputConfig: BlockInputOptions try {