Turn YouTube URLs into embedded players in Datasette
Project description
datasette-youtube-embed
Turn YouTube URLs into embedded players in Datasette
Installation
Install this plugin in the same environment as Datasette.
datasette install datasette-youtube-embed
Usage
Once installed, any columns containing URLs that look like one of these:
https://www.youtube.com/watch?v=xyzhttps://www.youtube.com/watch?v=xyz&start=30https://www.youtube.com/watch?v=xyz&start=30&end=50
Will be turned into YouTube embeds like this:
<lite-youtube videoid="xyz" params="start=30" style="min-width: 200px"></lite-youtube>
These will then be rendered using Lite YouTube Embed, which avoids loading the full YouTube embed until someone interacts with it.
Development
To set up this plugin locally, first checkout the code. Then create a new virtual environment:
cd datasette-youtube-embed
python3 -m venv venv
source venv/bin/activate
Now install the dependencies and test dependencies:
pip install -e '.[test]'
To run the tests:
pytest
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file datasette_youtube_embed-0.2.tar.gz.
File metadata
- Download URL: datasette_youtube_embed-0.2.tar.gz
- Upload date:
- Size: 7.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2c61a233fba79504998be7d6e1189122f222e36fc929370b2e0221c38c0f4a55
|
|
| MD5 |
1d84382a08bc5d37267896de6b3faf8f
|
|
| BLAKE2b-256 |
7ed464534924611e2a79babd560fae12ea7b0036075604a10da8fd6773cecb8e
|
Provenance
The following attestation bundles were made for datasette_youtube_embed-0.2.tar.gz:
Publisher:
publish.yml on simonw/datasette-youtube-embed
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
datasette_youtube_embed-0.2.tar.gz -
Subject digest:
2c61a233fba79504998be7d6e1189122f222e36fc929370b2e0221c38c0f4a55 - Sigstore transparency entry: 911128840
- Sigstore integration time:
-
Permalink:
simonw/datasette-youtube-embed@c49a8aba2ac1de863163ff20b486219b561b3b5d -
Branch / Tag:
refs/tags/0.2 - Owner: https://github.com/simonw
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@c49a8aba2ac1de863163ff20b486219b561b3b5d -
Trigger Event:
release
-
Statement type:
File details
Details for the file datasette_youtube_embed-0.2-py3-none-any.whl.
File metadata
- Download URL: datasette_youtube_embed-0.2-py3-none-any.whl
- Upload date:
- Size: 8.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a3f0aac8033850bed23b5863b3a6f5129437d616f8d827a9dc17cb0e31b5ad95
|
|
| MD5 |
250545b1b6c2e105586bb30d45bc2f81
|
|
| BLAKE2b-256 |
48ace9885958bd83c46f5bec6e7b621fc3d0946d12bced7dd6f52ced5b098c06
|
Provenance
The following attestation bundles were made for datasette_youtube_embed-0.2-py3-none-any.whl:
Publisher:
publish.yml on simonw/datasette-youtube-embed
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
datasette_youtube_embed-0.2-py3-none-any.whl -
Subject digest:
a3f0aac8033850bed23b5863b3a6f5129437d616f8d827a9dc17cb0e31b5ad95 - Sigstore transparency entry: 911128897
- Sigstore integration time:
-
Permalink:
simonw/datasette-youtube-embed@c49a8aba2ac1de863163ff20b486219b561b3b5d -
Branch / Tag:
refs/tags/0.2 - Owner: https://github.com/simonw
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@c49a8aba2ac1de863163ff20b486219b561b3b5d -
Trigger Event:
release
-
Statement type: