1.1.1 • Published 8 months ago

vuepress-plugin-replaceurl v1.1.1

Weekly downloads
-
License
MIT
Repository
github
Last release
8 months ago

vuepress-plugin-replaceurl

install

yarn add liyao52033/vuepress-plugin-replaceurl -D

Use

Default

// .vuepress/config.js
// or
// .vuepress/theme/index.js

module.exports = {
  plugins: ['replaceurl']
}

The Default configuration is for vuepress-plugin-autobar, it clean the cumbersome parameter.

Default Rule: [[/nav[\.\-_]*\d*[\.\-_]*/gi, ''], [/\d+[\.\-_]*/gi, '']]

  • before use: /nav.10.js/10-core/mian-xiang-dui-xiang/mian-xiang-dui-xiang.html

  • after use: /js/core/mian-xiang-dui-xiang/mian-xiang-dui-xiang.html

Customize

You can customize your replace rules. Example:

// .vuepress/config.js
// or
// .vuepress/theme/index.js

module.exports = {
  plugins: ['replaceurl', [/regex/i, 'new world']]
  // or multiple rules
  // plugins: ['replaceurl', [[/regex1/, 'world'], [/regex2/gi, 'world2']]]
}
1.1.1

8 months ago

1.1.0

8 months ago

1.0.5

8 months ago

1.0.4

8 months ago