https://github.com/wonism/react-google-ads
React component for google adsense
https://github.com/wonism/react-google-ads
Last synced: 6 months ago
JSON representation
React component for google adsense
- Host: GitHub
- URL: https://github.com/wonism/react-google-ads
- Owner: wonism
- License: mit
- Created: 2016-12-28T19:20:15.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2018-04-03T16:48:26.000Z (about 7 years ago)
- Last Synced: 2024-09-24T05:47:57.878Z (7 months ago)
- Language: JavaScript
- Size: 81.1 KB
- Stars: 7
- Watchers: 3
- Forks: 3
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# React Google Ads
> A Component for google adsense## Getting Started
```sh
# Installation with package manager
$ yarn add react react-dom react-google-ads
# or..
$ npm i -S react react-dom react-google-ads
```## Development
```sh
$ npm run demo
```
- access [localhost:8888](http://localhost:8888)## Production Bundle
```sh
$ npm run bundle
```## How to Use
### Parameters
| Parameter | Type | Remarks |
|:----------|:-------|:----------------|
| client | string | Required |
| slot | string | Required |
| style | object | - |
| format | string | default: 'auto' |### Basic
```js
import React from 'react';
import ReactDOM from 'react-dom';
import GoogleAds from '../src';const appRoot = document.getElementById('google-adsense');
ReactDOM.render(
, appRoot
);
```## Change Log
__1.0.0__
- Initial release__1.0.2__
- Added `className` property to add custom class to `` tag.__1.0.3__
- migrate `webpack`
- migrate `babel preset`__1.0.4__
- fix typos in `README.md`__1.0.5__
- add `prop-types` for `react^16`