Skip to content

leonardssh/use-lanyard

Folders and files

NameName
Last commit message
Last commit date

Latest commit

da352a9 Β· Oct 5, 2021

History

18 Commits
Aug 14, 2021
Aug 13, 2021
Aug 14, 2021
Aug 13, 2021
Aug 13, 2021
Aug 13, 2021
Aug 13, 2021
Oct 5, 2021
Aug 13, 2021
Aug 14, 2021
Aug 13, 2021
Aug 13, 2021
Aug 13, 2021
Aug 13, 2021

Repository files navigation

Logo

NPM version NPM downloads

Vue Use Lanyard

Use Lanyard API easily in your Vue app!

Report Bug Β· Request Feature Β· What Is Lanyard


Remember to 🌟 this Github if you πŸ’– it.


πŸ“¦ Installation

  • Using yarn: yarn add @leonardssh/use-lanyard
  • Using npm: npm i @leonardssh/use-lanyard
  • Using pnpm: pnpm add @leonardssh/use-lanyard

πŸ€“ Usage

✨ This plugin supports both REST and WebSocket methods.

Using without websocket:

import { useLanyard } from '@leonardssh/use-lanyard';

const { success, data, error } = await useLanyard({
	userId: 'USER_ID'
});

Using with websocket:

import { useLanyard, LanyardData } from '@leonardssh/use-lanyard';

await useLanyard({
	userId: 'USER_ID',
	socket: true,
	onPresenceUpdate(presence: LanyardData) {
		...
	}
});

πŸŽ‰ Thanks

πŸ‘¨β€πŸ’» Contributing

To contribute to this repository, feel free to create a new fork of the repository and submit a pull request.

  1. Fork / Clone and select the main branch.
  2. Create a new branch in your fork.
  3. Make your changes.
  4. Commit your changes, and push them.
  5. Submit a Pull Request here!

πŸ“‹ License

This project is licensed under the MIT License - see the LICENSE file for details.