Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/googleads/google-publisher-tag-samples
Google Publisher Tag (GPT) code samples.
https://github.com/googleads/google-publisher-tag-samples
admanager google googleads gpt samples
Last synced: 4 days ago
JSON representation
Google Publisher Tag (GPT) code samples.
- Host: GitHub
- URL: https://github.com/googleads/google-publisher-tag-samples
- Owner: googleads
- License: apache-2.0
- Created: 2020-10-13T08:50:13.000Z (about 4 years ago)
- Default Branch: main
- Last Pushed: 2024-11-07T20:12:12.000Z (5 days ago)
- Last Synced: 2024-11-07T21:21:15.264Z (5 days ago)
- Topics: admanager, google, googleads, gpt, samples
- Language: TypeScript
- Homepage: https://developers.google.com/publisher-tag/samples
- Size: 432 KB
- Stars: 38
- Watchers: 11
- Forks: 22
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
Awesome Lists containing this project
README
# Google Publisher Tag Samples
Samples for the Google Publisher Tag (GPT) library.
You can try these samples on our
[developer site](//developers.google.com/publisher-tag/samples/).## Project structure
[`dist/`](/dist) contains complete GPT samples, built from the templates in
[`samples/`](/samples). Each directory represents a single GPT sample, and each
sample has multiple output formats:* `/js/` - JavaScript (ES2020)
* `/legacyjs/` - JavaScript (ES5)
* `/ts/` - TypeScript[`samples/`](/samples) contains templates used to generate complete GPT samples.
Each template is stored in its own directory and consists of:* `index.njk` - A [Nunjucks](//mozilla.github.io/nunjucks/) template
containing sample-specific CSS and HTML content.
* `sample.ts` - Sample-specific GPT code, written in TypeScript.
* `README.md` - Sample-specific usage instructions.
* `.json` - Sample-specific metadata (title, description, etc.)[`src/`](/src) contains the code necessary to transform templates into complete
samples.[`test/`](/test) contains tests for [`src/`](/src).
## Development
### Build
1. `npm i` - Install dependencies.
2. `npm run build` - Build all targets and update `dist/` folder.### Test
1. `npm run test` - Run all tests.## Contributing
Pull requests are welcome! Please sign
[this Google Code contributor agreement](CONTRIBUTING.md) before submitting.