Skip to content

Commit

Permalink
Merge pull request #41 from vb/feat/noembed-support
Browse files Browse the repository at this point in the history
Feat/noembed support
  • Loading branch information
vb authored Apr 23, 2021
2 parents 80b7809 + 56c7be3 commit 653970d
Show file tree
Hide file tree
Showing 9 changed files with 56 additions and 115 deletions.
11 changes: 2 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,6 @@ General options and corresponding defaults

```js
lazyframe(elements, {
apikey: undefined,
debounce: 250,
lazyload: true,
autoplay: true,
Expand All @@ -96,12 +95,6 @@ lazyframe(elements, {
});
```

### `apikey`

If you want to load a thumbnail and title for a YouTube video you'll have to have an API key with the YouTube data API library enabled. Get it from [here](https://console.developers.google.com/)

_If you don't feel like getting a key, just use your own thumbnail and title in data-thumbnail and data-title attribute_

### `debounce`

Value (in milliseconds) for when the update function should run after the user has scrolled. [More here](https://css-tricks.com/the-difference-between-throttling-and-debouncing/)
Expand Down Expand Up @@ -147,11 +140,11 @@ Attribute for theming lazyframe. Currently supported values are `youtube`, `yout

### `data-title`

Attribute for custom title. Leave empty to get value from API.
Attribute for custom title. Leave empty to get value from noembed.com.

### `data-thumbnail`

Attribute for custom thumbnail. Leave empty to get value from API.
Attribute for custom thumbnail. Leave empty to get value from noembed.com.

### `data-src`

Expand Down
2 changes: 1 addition & 1 deletion dist/lazyframe.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 653970d

Please sign in to comment.