{"_rev":"52-d4e2c2607f8eee54dc631cd5e58adc9f","time":{"created":"2023-05-23T15:51:19.460Z","1.0.0":"2023-03-24T11:10:37.661Z","modified":"2023-05-23T15:51:19.766Z","1.0.1":"2023-03-24T17:33:34.214Z","1.0.2":"2023-03-30T11:13:54.616Z","1.0.3":"2023-03-30T11:24:13.152Z","1.0.4":"2023-03-31T10:48:19.406Z","1.0.5":"2023-03-31T11:35:55.759Z","1.0.6":"2023-03-31T12:37:04.993Z","1.0.7":"2023-03-31T12:42:50.583Z","1.0.8":"2023-03-31T12:49:11.039Z","1.0.9":"2023-03-31T12:52:56.548Z","1.1.0":"2023-03-31T12:53:56.044Z","1.1.1":"2023-04-04T10:09:39.625Z","1.1.2":"2023-04-04T10:11:36.123Z","1.1.3":"2023-04-04T13:47:39.890Z","1.1.4":"2023-04-06T07:45:45.501Z","1.1.5":"2023-04-06T13:09:33.282Z","1.1.6":"2023-04-06T13:27:41.411Z","1.1.7":"2023-04-06T13:31:03.316Z","1.1.8":"2023-04-06T13:34:23.240Z","1.1.9":"2023-04-06T13:35:14.403Z","1.2.0":"2023-04-06T13:39:07.087Z","1.2.1":"2023-04-06T13:39:55.846Z","1.2.2":"2023-04-06T16:47:44.156Z","1.2.3":"2023-04-06T16:51:46.803Z","1.2.4":"2023-04-06T16:54:39.773Z","1.2.5":"2023-04-06T16:56:27.032Z","1.2.6":"2023-04-10T16:03:21.574Z","1.2.7":"2023-04-10T16:04:50.878Z","1.2.8":"2023-04-12T18:07:59.334Z","1.2.9":"2023-04-12T18:18:48.026Z","1.3.1":"2023-04-12T18:22:25.810Z","1.3.2":"2023-04-12T18:23:57.221Z","1.3.3":"2023-04-12T18:24:19.212Z","1.3.4":"2023-04-12T18:25:01.692Z","1.3.5":"2023-04-12T18:26:26.503Z","1.3.6":"2023-04-12T18:27:44.292Z","1.3.7":"2023-04-12T18:28:32.381Z","1.3.8":"2023-04-12T18:35:28.975Z","1.3.9":"2023-04-12T18:36:50.904Z","1.4.0":"2023-04-12T18:37:11.524Z","1.4.1":"2023-04-12T18:37:44.445Z","1.4.2":"2023-04-12T18:38:43.264Z","1.4.3":"2023-04-12T18:39:17.018Z","1.4.4":"2023-04-12T18:39:41.271Z","1.4.5":"2023-04-23T20:10:35.890Z","1.4.6":"2023-04-23T20:16:25.189Z","1.4.7":"2023-04-23T20:22:25.219Z","1.4.8":"2023-04-28T05:28:59.377Z","1.4.9":"2023-04-28T05:42:50.403Z","1.5.0":"2023-04-30T13:34:47.934Z","1.5.1":"2023-04-30T13:51:38.006Z","1.5.2":"2023-05-23T15:51:19.602Z"},"_id":"ad-sdk-persona","name":"ad-sdk-persona","dist-tags":{"latest":"1.5.2"},"versions":{"1.5.2":{"name":"ad-sdk-persona","version":"1.5.2","description":"``` npm i ad-sdk-persona ```","main":"script.js","scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"author":"","license":"ISC","gitHead":"be83febf918e0569641066c1c19d2c0c3eb28a21","_id":"ad-sdk-persona@1.5.2","_nodeVersion":"18.12.1","_npmVersion":"8.19.2","dist":{"integrity":"sha512-XxvbHayzfWhAmz9+Rn/Waj00hlkUDzavp448wOOtN/ElYcjF25Wl1t7fPI3k1Mzzw0ZsUynUH23NQGMzY+W7Cg==","shasum":"25bb8138afb363ccd885564e4632bac5769c113e","tarball":"https://registry.npmjs.org/ad-sdk-persona/-/ad-sdk-persona-1.5.2.tgz","fileCount":3,"unpackedSize":7880,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIF5al5RDqGFmEoXQa6Okv34PaLSRUwI+t07C/nNWjsPuAiBOYjvtpYus2iU4XNVnKZIi5HCPqWJU0uv1+kp3N4Byqw=="}]},"_npmUser":{"name":"persona3","email":"data@persona3.io"},"directories":{},"maintainers":[{"name":"persona3","email":"data@persona3.io"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/ad-sdk-persona_1.5.2_1684857079460_0.8355061470958265"},"_hasShrinkwrap":false}},"maintainers":[{"name":"persona3","email":"data@persona3.io"}],"description":"``` npm i ad-sdk-persona ```","license":"ISC","readme":"# persona-adsdk\n## Installing the SDK\n\n```\nnpm i ad-sdk-persona\n```\n\n## Create a react component to display an Ad\n\n```\nimport React, { Component } from 'react';\nimport AdDisplay from \"ad-sdk-persona\";\n\nclass MyComponent extends Component {\n    constructor(props) {\n        super(props);\n        this.adDisplayed = false;\n    }\n\n    componentDidMount() {\n        if (!this.adDisplayed) {\n            const myAd = new AdDisplay(\"AIzaSyDj5IlXqxL_S_yW7HMsxWjk4Gh9OnVmgiA\");\n            myAd.display('my-ad-container', { backgroundColor: 'black', display: 'contents' });\n            this.adDisplayed = true;\n        }\n    }\n\n    render() {\n        return (\n            <div>\n                <h1>Welcome to my website</h1>\n                <div id=\"my-ad-container\"></div>\n            </div>\n        );\n    }\n}\n\nexport default MyComponent;\n```\nOnce the component is created import and use the component to display ad anywhere.\n\n## Initializing SDK\n\nAfter importing the SDK from\n```\nimport AdDisplay from \"ad-sdk-persona\";\n```\ncreate instance of AdDisplay\n```\nconst myAd = new AdDisplay();\n```\nnow call the display function \n\n```\nmyAd.display(my-ad-container, style);\n```\nthis contains two parameters\n- The first parameter refers to the container's ID to display the ad inside a particular div, argument typer 'string'\n- The second parameter refers to the styling of the ad div\nexample\n```\nmyAd.display('my-ad-container', { backgroundColor: 'black', display: 'contents' });\n```","readmeFilename":"README.md"}