0.0.0 • Published 2 years ago

@juniodevpackages/adblock-plus v0.0.0

Weekly downloads
-
License
ISC
Repository
github
Last release
2 years ago

Adblock Plus for ReactJS

Using the hook useAdBlockPlus

  import { useAdBlockPlus } from 'adblock-plus'

  const isAdBlockDetect = useAdBlockPlus()

  if (isAdBlockDetect) {
    return (
      <h1>Adblock detected</h1>
    )
  }

Using the component AdBlockPlusDetect

import AdBlockPlusDetect from 'adblock-plus'

export const MyApp = () => {

  return (
    <AdBlockPlusDetect title="AdBlock detected" description="To use our platform, deactivate your AdBlock">
      <h1>MyApp title</h1>
    </AdBlockPlusDetect>
  )

}