https://github.com/app-generator/sticky-media
Simple Vanilla JS library for Sticky Media content | AppSeed
https://github.com/app-generator/sticky-media
appseed npm-package sticky-elements sticky-video
Last synced: about 1 month ago
JSON representation
Simple Vanilla JS library for Sticky Media content | AppSeed
- Host: GitHub
- URL: https://github.com/app-generator/sticky-media
- Owner: app-generator
- License: mit
- Created: 2023-02-10T06:58:28.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2023-07-25T19:59:52.000Z (almost 3 years ago)
- Last Synced: 2025-06-16T10:48:19.166Z (about 1 year ago)
- Topics: appseed, npm-package, sticky-elements, sticky-video
- Language: JavaScript
- Homepage: https://www.npmjs.com/package/sticky-media
- Size: 2.99 MB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE.md
Awesome Lists containing this project
README
# [Sticky Media](https://github.com/app-generator/sticky-media)
Simple Vanilla JS library for `Sticky Media` content (YouTube videos) - actively supported by [AppSeed](https://appseed.us/).
- [Sticky Media](https://sticky-media.appseed-srv1.com/) - `Live DEMO`
- Free [Support](https://appseed.us/support/) via `Email` & `Discord`
- Supported YouTube Links(just a few from [this](https://gist.github.com/rodrigoborgesdeoliveira/987683cfbfcc8d800192da1e73adc486) list)
- `https://www.youtube.com/watch?v=EtMCK5AmdQI`
- `https://youtube.com/embed/9HqyJ_80JwI`
- `https://youtu.be/IM-PJrlgBe8`
- `https://m.youtube.com/v/dQw4w9WgXcQ`
- If the VideoID cannot be extracted the URL is handled via `window.open(VideoId)`

## Table of contents
- [Environment](#environment)
- [Manual Preview](#manual-preview)
- [Quick use](#quick-use)
- [License](#license)
## Environment
Project create with:
- Node JS >= 14x
## Manual Preview
> Using **Python**
`$ python -m http.server 9999`
> Using **PHP**
`$ php -S localhost:9999`
## Setup
Install it locally using PyPI:
```bash
$ npm i sticky-media
```
## Quick use
Simply and functional example/s of use.
> **Step 1**: `Import the JS` (local storage)
```javascript
```
Or you can simply use `CDN storage`:
```javascript
```
> **Step 2**: `Init` the library
```javascript
// Default -> "sticky-popup" CSS class is used
var stickyMediaInstance = new StickyMedia();
// Custom -> "my-sticky-class" is used to trigger the popup
var stickyMediaInstance = new StickyMedia( {'cssClass':'my-sticky-class'} );
```
> **Step 3**: `Use it` in the code
- `Video ID`: **GET parameter**
```javascript
Video_1
```
- `Video ID`: **URI segment**
```javascript
Video_2
```
## License
@MIT License
## Resources
- More [Tools for developers](https://appseed.us/developer-tools/) - `all free`
- Free [Support](https://appseed.us/support/) via `Email` & `Discord`
---
[Sticky Media](https://github.com/app-generator/sticky-media) - Simple Vanilla JS library provided by [AppSeed](https://appseed.us)