count-strings

counts strings

Usage no npm install needed!

<script type="module">
  import countStrings from 'https://cdn.skypack.dev/count-strings';
</script>

README

Usage:

var count = require('count-strings');
count('foo bar foo bar foo', 'foo') === 3