@blivesta/util-can-use-dom

Just a small JavaScript utilities

Usage no npm install needed!

<script type="module">
  import blivestaUtilCanUseDom from 'https://cdn.skypack.dev/@blivesta/util-can-use-dom';
</script>

README

@blivesta/util-can-use-dom

Install

yarn add @blivesta/util-can-use-dom

Usage

import { canUseDom } from '@blivesta/canUseDom'

if (canUseDom ? document : null) {
  // Your Scripts
}

License

Released under the MIT license.