Skip to content

Commit

Permalink
Remove warning for remark 12
Browse files Browse the repository at this point in the history
  • Loading branch information
wooorm committed Aug 5, 2021
1 parent f2c4cad commit ee5d8e4
Showing 1 changed file with 0 additions and 16 deletions.
16 changes: 0 additions & 16 deletions index.js
Original file line number Diff line number Diff line change
@@ -1,25 +1,9 @@
import jsYaml from 'js-yaml'

let warningIssued

// Modify remark to read configuration from comments.
export default function remarkYamlConfig() {
const data = this.data()

// Old remark.
/* c8 ignore next 11 */
if (
!warningIssued &&
this.Compiler &&
this.Compiler.prototype &&
this.Compiler.prototype.visitors
) {
warningIssued = true
console.warn(
'[remark-heading-gap] Warning: please upgrade to remark 13 to use this plugin'
)
}

// Other extensions
/* c8 ignore next */
if (!data.toMarkdownExtensions) data.toMarkdownExtensions = []
Expand Down

0 comments on commit ee5d8e4

Please sign in to comment.