Socket
Socket
Sign inDemoInstall

vue3-instagram-feed

Package Overview
Dependencies
29
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    vue3-instagram-feed

A Vue 3 component to display a users Instagram posts using Instagram Basic Graph API


Version published
Weekly downloads
40
decreased by-39.39%
Maintainers
1
Install size
13.0 MB
Created
Weekly downloads
 

Readme

Source

Vue 3 Instagram Feed/Gallery

MIT v0.1.2 JavaScript Style Guide

A Vue 3 component that displays a basic Instagram feed using Instagram Basic Graph API and your Facebook access token.

Important: This only works with Vue 3 as I am using the composition API. You also need to generate an Instagram Access Token from the Meta Developer Portal.

Installation

yarn add vue3-instagram-feed

OR

npm install vue3-instagram-feed

Usage

To display a simple gallery with a set number of images.

Props:

  • accessToken: Required.
  • count: Required. Defines the number of images.
  • pagination: Optional. Takes a boolean.
<template>
  <InstagramFeed
    :count="12"
    accessToken="<your token here>"
    :pagination="true"
  />
</template>

Main.js

import { createApp } from "vue";
import App from "./App.vue";

import InstagramFeed from "vue3-instagram-feed";
import "vue3-instagram-feed/dist/style.css";

createApp(App).use(InstagramFeed).mount("#app");

Styling

vue3-instagram-feed includes default styling (dist/styles.css) with that you can use as a base to create your own CSS. All the component's elements are inside a div which acts a wrapper for the icons and the input.

The styles are as shown below, you can ovveride them as you wish.

.instagram-wrapper {
  max-width: 93.5rem;
  margin: 0 auto;
  padding: 0 2rem;
}
.instagram-gallery {
  display: flex;
  flex-wrap: wrap;
  margin: -1rem, -1rem;
  padding-bottom: 3rem;
}
.instagram-gallery-item {
  position: relative;
  flex: 1 0 22rem;
  margin: 1rem;
  color: #fff;
  cursor: pointer;
}
.instagram-gallery-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

Keywords

FAQs

Last updated on 04 May 2022

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc