sf

svelte-fullscreen

Component that performs fullscreen in DOM Elements

Showing:

Popularity

Downloads/wk

211

GitHub Stars

28

Maintenance

Last Commit

16d ago

Contributors

1

Package

Dependencies

1

License

MIT

Type Definitions

Built-In

Tree-Shakeable

Yes?

Categories

Readme

Svelte FullScreen

npm versionLicense: MITBuild StatusNetlify StatusLanguage grade: JavaScript

Component that performs fullscreen in DOM Elements

Installation

npm i svelte-fullscreen
// OR
yarn add svelte-fullscreen

Note: to use this library in sapper, install as devDependency. See the link.

Local demo:

git clone https://github.com/andrelmlins/svelte-fullscreen.git
cd svelte-fullscreen
yarn install && yarn start

Examples

An example of how to use the library:

<script>
  import Fullscreen from "svelte-fullscreen";
</script>

<style>
  div {
    background-color: red;
    width: 120px;
    height: 120px;
  }
</style>

<Fullscreen let:onRequest let:onExit>
  <div>
    <button on:click={() => onRequest()}>FullScreen</button>
    <button on:click={() => onExit()}>Screen</button>
  </div>
</Fullscreen>

Properties

Raw component props (before transform):

PropTypeDescription
changefuncCall in change
errorfuncCall in error

Slot Properties

Raw component props (before transform):

PropTypeDescription
onTogglefuncCall for fullscreen toggle
onExitfuncCall for fullscreen exit
onRequestfuncCall for fullscreen enter

NPM Statistics

Download stats for this NPM package

NPM

License

Svelte FullScreen is open source software licensed as MIT.

Rate & Review

Great Documentation0
Easy to Use0
Performant0
Highly Customizable0
Bleeding Edge0
Responsive Maintainers0
Poor Documentation0
Hard to Use0
Slow0
Buggy0
Abandoned0
Unwelcoming Community0
100