Giter Club home page Giter Club logo

taquito-pinata-tezos-nft's Introduction

Learn how to create NFTs on Tezos using Taquito and Pinata

This is a tutorial dapp to show how to create NFTs on Tezos with Taquito and Pinata

Structure of the project

  • Frontend folder: contains the dapp users interact with to provide a picture, title and description for their NFT
  • Backend folder: contains the server app to pin the picture and the metadata to Pinata (IPFS)
  • Contract: contains the FA2 contract recording the NFTs

Getting started:

  • For the frontend dapp:
npm install
npm run dev

You must provide a valid server URL in the App.svelte file:

// Replace `https://my-cool-backend-app.com` with the address where you deployed the backend app

const serverUrl =
  process.env.NODE_ENV !== "production"
    ? "http://localhost:8080"
    : "https://my-cool-backend-app.com";
  • For the backend dapp:
npm install
npm run dev

You must provide a valid app URL for the CORS options:

// Replace `https://my-cool-nft-app.com` with the URL of your app

const corsOptions = {
  origin: ["http://localhost:8082", "https://my-cool-nft-app.com"],
  optionsSuccessStatus: 200 // some legacy browsers (IE11, various SmartTVs) choke on 204
};
  • For the contract: The code of the contract can be copy-pasted into the Ligo web IDE and originated from there. The default storage is available in a comment block at the bottom of the contract.
  • Pinata: you will need an account on Pinata and API keys. Keep your API keys secret!

taquito-pinata-tezos-nft's People

Contributors

claudebarde avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

taquito-pinata-tezos-nft's Issues

still having issues building

Frontend built, backend no:

12 pinata = pinataSDK(process.env.PINATA_API_KEY, process.env.PINATA_SECRET_KEY);
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

src/index.ts:15:12 - error TS2348: Value of type 'typeof PinataClient' is not callable. Did you mean to include 'new'?

15 pinata = pinataSDK(PinataKeys.apiKey, PinataKeys.apiSecret);
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Found 2 errors in the same file, starting at: src/index.ts:12

npm ERR! code 2
npm ERR! path /Users/James/taquito-pinata-tezos-nft/backend
npm ERR! command failed
npm ERR! command sh -c tsc

Two small changes required for set up

Hi @claudebarde , thanks for the great article! I ran into two small issues setting this up locally.

I'm not able to submit a PR, but in case anyone comes across this, these are the changes I needed to make:

In backend/src/index.ts:

-  const PinataKeys = require("./PinataKeys");
+  const PinataKeys = require("./PinataKeys").default;

In frontend/src/App.svelte:

-          data.status === 200 &&
+          data.status === true &&

Florencenet is deprecated

Hi @claudebarde, thanks for the excellent tutorial. I think I almost have it working however Florencenet is deprecated as of August 6, 2021

I assume changing the references to Hangzhounet will fix this however I'm unable to submit a PR

Cheers!

Tutorial is hard to follow

Hi Claude!

Assuming this is the tutorial:
https://wiki.tezos.com/build/create-a-tezos-token/nft

It looks like the tutorial is written for production but there's no instructions on setting up Heroku or any path/filenames for the code snippets.

Could you please add some steps to set up Heroku with the url please? Or how to get up and running on localhost?

I tried running npm install on macbook in frontend directory but got:

npm ERR! path /Users/leotreasure/taquito-pinata-tezos-nft/frontend/node_modules/node-sass

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.