solana-developers / create-solana-dapp

CLI for creating Solana dApps on the fly
https://npmjs.com/package/create-solana-dapp
MIT License
363 stars 108 forks source link

Invalid init script for NextJS + Tailwind + no Anchor #88

Closed meta-light closed 1 month ago

meta-light commented 1 month ago
■  Error: Invalid init script: [
│    {
│      "code": "invalid_type",
│      "expected": "array",
│      "received": "undefined",
│      "path": [
│        "instructions"
│      ],
│      "message": "Required"
│    }
│  ]
▲  Something went wrong
meta-light commented 1 month ago

Looks like it did install everything just threw an error at the end

beeman commented 1 month ago

Thanks for reporting this issue, I will fix it.

beeman commented 1 month ago

This has been fixed in version 4.0.1.

$ pnpx create-solana-dapp
┌  create-solana-dapp 4.0.1
│
◇  Enter project name
│  fixed-error
│
◇  Select a framework
│  Next.js
│
◇  Select a template
│  next-tailwind
│
◇  Cloned template to /private/tmp/solana-local/fixed-error
│
◇  Installed via pnpm
│
◇  Repository does not have an init script
│
◇  Initialized git repo
│
◇  Installation successful! ───────────────────────────╮
│                                                      │
│  That's it!                                          │
│                                                      │
│  Change to your new directory and start developing:  │
│                                                      │
│  cd ./fixed-error                                    │
│                                                      │
│  Start the app:                                      │
│                                                      │
│  pnpm run dev                                        │
│                                                      │
├──────────────────────────────────────────────────────╯
│
└  Good luck with your project!

To test it, please run one of the following commands:

# pnpm based project
pnpx create-solana-dapp
# npm based project
npx create-solana-dapp

To be sure you're on this version, and avoid any local caches, you can add the version using this syntax:

# pnpm based project
pnpx create-solana-dapp@4.0.1
# npm based project
npx create-solana-dapp@4.0.1