fast-diy

A small tool to quickly format Discuz! diy module.

Usage no npm install needed!

<script type="module">
  import fastDiy from 'https://cdn.skypack.dev/fast-diy';
</script>

README

fast-diy

A small tool to quickly format Discuz! diy module.

Install from npm

$ npm install -g fast-diy

How to use

Add a "diy" class name to each html tag which is going to be DIYed. Then:

$ fast-diy INPUT.html OUTPUT.html

Example input:

<div class="diy">
  <p> test </p>
</div>

Example output

<!--[diy=diy-f78e9de8]--><div>
  <p> test </p>
</div><!--[/diy]-->

License

MIT