Skip to content

This is a simple example for fetching reviews from yotpo and styling it with tailwind CSS and gravatar.

License

Notifications You must be signed in to change notification settings

kamephis/yotpo-api-example

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 

Repository files navigation

Yotpo Reviews

This code retrieves reviews from the Yotpo API and displays them on a webpage.

Functionality

The code does the following:

  1. Imports the necessary libraries and styles.
  2. Defines the layout of the webpage.
  3. Retrieves the Yotpo API credentials.
  4. Fetches the reviews from the Yotpo API.
  5. Formats the reviews into HTML elements.
  6. Displays the formatted reviews on the webpage.

The webpage displays the following information for each review:

  1. The user's avatar (from Gravatar).
  2. The review title and content.
  3. The user's name and the review date.
  4. The star rating (as a row of stars).

How to Use

To use this code, you will need to:

  1. Replace APP_KEY and AUTH_TOKEN with your own Yotpo API credentials.
  2. Copy the code into an HTML file.
  3. Open the HTML file in a web browser.
  4. The code will fetch the reviews from the Yotpo API and display them on the webpage.

Dependencies

This code relies on the following libraries:

  1. tailwindcss (from a CDN)
  2. crypto-js (from a CDN)
  3. font-awesome (from a CDN)

License

This code is licensed under the GPL License.

About

This is a simple example for fetching reviews from yotpo and styling it with tailwind CSS and gravatar.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages