1.1.4 • Published 8 months ago

@embedz/svelte v1.1.4

Weekly downloads
-
License
MIT
Repository
github
Last release
8 months ago

embedz

NPM MIT License

Easy, dependency free embeds for Svelte and Vue.

Demo

Installation

# npm
npm install @embedz/svelte
# pnpm
pnpm install @embedz/svelte
# yarn
yarn add @embedz/svelte

Usage

<script>
  import { Dailymotion, Vimeo, YouTube } from "@embedz/svelte";
</script>

<YouTube 
  id="C7eGZUBdL4g" 
  posterquality="max"
/>

Youtube

id

type: string

<YouTube id="C7eGZUBdL4g" />

You can also pass in the full URL for the video

<YouTube id="https://youtu.be/C7eGZUBdL4g" />

poster

type: string

<YouTube
  id="C7eGZUBdL4g"
  poster="https://picsum.photos/1280/720"
/>

posterquality

type: "max" | "high" | "default" | "low"

default: "default"

<YouTube
  id="C7eGZUBdL4g"
  posterquality="low"
/>

params

type: string

<YouTube
  id="C7eGZUBdL4g"
  params="controls=0&mute=1"
/>

ratio

type: string

<YouTube
  id="C7eGZUBdL4g"
  ratio="4:3"
/>

title

type: string

<YouTube
  id="C7eGZUBdL4g"
  title="Rock the House"
/>

Vimeo

id

type: string

<Vimeo id="32001208" />

You can also pass in the full URL for the video

<Vimeo id="https://vimeo.com/32001208" />

poster

type: string

<Vimeo
  id="32001208"
  poster="https://picsum.photos/1280/720"
/>

posterquality

type: "max" | "high" | "default" | "low"

default: "default"

<Vimeo
  id="32001208"
  posterquality="low"
/>

params

type: string

<Vimeo
  id="32001208"
  params="controls=0&mute=1"
/>

ratio

type: string

<Vimeo
  id="32001208"
  ratio="4:3"
/>

title

type: string

<Vimeo
  id="32001208"
  title="Earth"
/>

Dailymotion

id

type: string

<Dailymotion id="x8e31lf" />

You can also pass in the full URL for the video

<Dailymotion id="https://dai.ly/x8e31lf" />

poster

type: string

<Dailymotion 
  id="x8e31lf"
  poster="https://picsum.photos/1280/720"
/>

posterquality

type: "max" | "high" | "default" | "low"

default: "default"

<Dailymotion 
  id="x8e31lf"
  posterquality="low"
/>

params

type: string

<Dailymotion 
  id="x8e31lf"
  params="mute=true&loop=false"
/>

ratio

type: string

<Dailymotion 
  id="x8e31lf"
  ratio="4:3"
/>

title

type: string

<Dailymotion 
  id="x8e31lf"
  title="Dolby Vision"
/>

Development

git clone https://github.com/embedz/embedz.git
cd embedz/packages/svelte
npm install
npm run dev -- --open

License

Licensed under the MIT license.

Contributors

Contributions are welcome! Please feel free to submit a Pull Request.

1.1.4

8 months ago

1.1.3

8 months ago

1.1.2

8 months ago

1.1.1

8 months ago

1.1.0

8 months ago

1.0.48

9 months ago

1.0.47

9 months ago

1.0.46

9 months ago

1.0.45

9 months ago

1.0.44

9 months ago

1.0.43

9 months ago

1.0.42

9 months ago

1.0.41

9 months ago

1.0.40

9 months ago

1.0.39

9 months ago

1.0.38

9 months ago

1.0.37

9 months ago

1.0.36

9 months ago

1.0.35

9 months ago

1.0.34

9 months ago

1.0.33

9 months ago

1.0.32

9 months ago

1.0.31

9 months ago

1.0.30

9 months ago

1.0.29

9 months ago

1.0.28

9 months ago

1.0.27

9 months ago

1.0.26

9 months ago

1.0.25

9 months ago

1.0.24

9 months ago

1.0.23

9 months ago

1.0.22

9 months ago

1.0.21

9 months ago

1.0.20

9 months ago

1.0.19

9 months ago

1.0.18

9 months ago

1.0.17

9 months ago

1.0.16

9 months ago

1.0.15

9 months ago

1.0.14

9 months ago

1.0.13

9 months ago

1.0.12

9 months ago

1.0.11

9 months ago

1.0.10

9 months ago

1.0.9

9 months ago

1.0.8

9 months ago

1.0.7

9 months ago

1.0.6

9 months ago

1.0.5

9 months ago

1.0.4

9 months ago

1.0.3

9 months ago

1.0.2

9 months ago

1.0.1

9 months ago

1.0.0

9 months ago