pinata-expo
v0.0.2
Published
A collection of tools for using Pinata with Expo
Readme
pinata-expo
This repo contains packages that are compatible with React Native and Expo for uploading files to Pinata.
[!WARNING] This package is still under development, please contact us if you have any issues!
Development
The pinata-expo monorepo uses pnpm to manage workspaces and building packages. The structure is as follows:
.
├── examples
│ ├── expo-app
│ └── expo-server
├── package.json
├── packages
│ └── hooks
├── pnpm-lock.yaml
├── pnpm-workspace.yaml
└── README.mdInstallation
To start clone the repo and install dependencies
git clone https://github.com/PinataCloud/pinata-expo
cd pinata-expo
pnpm installBuilding
Move into the packages/hooks package to build it
cd packages/hooks
pnpm run buildBuilding will create a dist folder which will be accessible to other packages through workspace:* as seen in the expo-app example.
"pinata-expo-hooks": "workspace:*",Examples
The examples folder contains an Expo app and a Hono server you can use together for testing.
Start by setting up the server, where you will need to create a .dev.vars file with the following contents:
PINATA_JWT=YOUR_PINATA_JWT
GATEWAY_URL=yourgateway.mypinata.cloudBe sure to sub out the example values with your own. Then start up the dev server:
pnpm run devTo use the expo-app simply move into that package, install dependencies, then start up the dev server.
cd examples/expo-app
pnpm install
pnpm run start