npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@solana-mobile/solana-mobile-expo-template

v2.0.1

Published

This template is a ready-to-go Expo dApp that offers:

Downloads

509

Readme

Solana Mobile Expo Template

This template is a ready-to-go Expo dApp that offers:

  • Pre-installed standard SDKs like Mobile Wallet Adapter and @solana/web3.js
  • Required polyfills like react-native-get-random-values and Buffer installed.
  • Simple React UI Components like ConnectWalletButton, RequestAirdropButton, SignMessageButton.

This is only fully functional on Android.

Tech Stack

  • Mobile Wallet Adapter for connecting to wallets and signing transactions/messages
  • web3.js for constructing transactions and an RPC connection client.

Prerequisites

  • An Expo account.
  • React Native and Android Envrionment setup
    • An Android device/emulator.
    • Install an MWA compliant wallet app on your device/emulator.

Usage

Initialization

Initialize the template with:

yarn create expo-app --template @solana-mobile/solana-mobile-expo-template

Choose your project name then navigate into the directory.

Build and run the app

Follow the "Running the app" section in the Expo Setup guide to launch the template as a custom development build.

Troubleshooting

  • Metro has encountered an error: While trying to resolve module @solana-mobile/mobile-wallet-adapter-protocol...

    • This is an on-going issue when using npm install to install the Expo template.
    • To mitigate, clean your project dependencies and reinstall with yarn install
  • The package 'solana-mobile-wallet-adapter-protocol' doesn't seem to be linked. Make sure: ...

  • failed to connect to...

    • This is an Expo error that can occur when trying to connect to the dev server on certain Wifi networks.
    • To fix, try starting the dev server with the --tunnel command (npx expo start --dev-client --tunnel)
  • Error: crypto.getRandomValues() not supported

    • This is a polyfill issue when trying to use certain functions from the @solana/web3.js in a React Native/Expo environment.
    • To fix, ensure your App properly imports and uses the polyfills like in this guide.
  • error Failed to load configuration of your project.
  • Looks like your iOS environment is not properly set:
    • You can ignore this during template initialization and build the Android app as normal. This template is only compatible with Android.
  • Usage Error: It seems you are trying to add a package using a https:... url; we now require package names to be explicitly specified.
    • This error happens on certain versions of yarn, and occurs if you try to initialize the template through the Github repo URL, rather than the npm package. To avoid this, use the @solana-mobile/solana-mobile-dapp-scaffold package as specified, or downgrade your yarn version to classic (1.22.x).
  • error Couldn't find the ".../@solana-mobile/solana-mobile-dapp-scaffold/template.config.js file inside "@solana-mobile/solana-mobile-dapp-scaffold" template.
    • This is a known error that occurs with certain versions of yarn (>= 3.5.0). It is fixed by running the cli command with the --npm flag or downgrading your version of yarn.