Skip to content

Commit

Permalink
Fix/starter vite (#187)
Browse files Browse the repository at this point in the history
* Bitte Protocol AI Minter

* ai minter bitte

* ai minter bitte

* ai minter bitte

* fix starter vite

* fix starter vite

* fix starter vite

* fix starter vite

* fix starter vite

* fix starter vite

* Update README.md

---------

Co-authored-by: Rui Santiago <ruisantiagomr@gmail.com>
  • Loading branch information
rubenmarcus and sainthiago authored Sep 25, 2024
1 parent 9700636 commit 8350a8f
Show file tree
Hide file tree
Showing 6 changed files with 42 additions and 24 deletions.
30 changes: 24 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,25 +3,43 @@

## Templates



### Starter Templates

`Disclaimer: We do not officially support create-react-app due to numerous issues with packages used for crypto dApps. Additionally, it is not recommended by the React Team. For a SPA project, we recommend using React Vite.`

| Template | Demo |
|--|--|
| [Starter](./starter-next/) | [Demo](https://starter.mintbase.xyz/) |
| [Starter Next](./starter-next/) | [Demo](https://starter.mintbase.xyz/) |
| [Starter React Vite](./starter-vite/)| [Demo](https://starter-react-vite.mintbase.xyz/) |


### AI Templates

| Template | Demo |
|--|--|
| [AI Chat](./ai-chat/) | [Demo](https://ai-chat.mintbase.xyz/) |
| [AI Minter](./ai-minter/) | [Demo](https://ai-minter.mintbase.xyz/) |
| [Coingecko AI Plugin Simple](./coingecko-ai-plugin-simple/) | [Demo](https://wallet.bitte.ai/smart-actions/prompt/what%20can%20you%20help%20me%20with?mode=debug&agentId=coingecko-ai-simple.vercel.app) |
| [Coingecko AI Plugin Advanced](./coingecko-ai-plugin-advanced/) | [Demo](https://wallet.bitte.ai/smart-actions/prompt/what%20can%20you%20help%20me%20with?mode=debug&agentId=coingecko-ai.vercel.app) |


### NFT Templates

| Template | Demo |
|--|--|
| [Blogchain](./blogchain/) | [Demo](https://blogchain.mintbase.xyz) |
| [Contract Deployer](./contract-deployer/) | [Demo](https://contract-deployer-template.mintbase.xyz/) |
| [Minter](./minter/) | [Demo](https://minter.mintbase.xyz/) |
| [Minsta](https://github.com/Mintbase/minsta) | [Demo](https://minsta.mintbase.xyz/) |
| [Marketplace](./marketplace/) | [Demo](https://marketplace-template.mintbase.xyz/) |
| [NFT Stripe Checkout](./nft-stripe-checkout/) | [Demo](https://nft-stripe-checkout.mintbase.xyz/)
| [NFT Stripe Checkout](./nft-stripe-checkout/) | [Demo](https://nft-stripe-checkout.mintbase.xyz/)
| [Token Drop](./simple-token-drop) | [Demo](https://token-drop-template.mintbase.xyz/) |


## Contribution Guidelines

We're excited to invite you to contribute templates that showcase the capabilities of web3 projects on the Near Protocol. These templates can serve as starter projects for developers or exemplify specific use cases, inspiring real-world problem-solving.
We're excited to invite you to contribute templates that showcase the capabilities of web3 projects on the Near Protocol. These templates can serve as starter projects for developers or exemplify specific use cases, inspiring real-world problem-solving.

Here are some instructions to get started:

Expand Down Expand Up @@ -81,7 +99,7 @@ Add a thumbnail to your project <img src="https://i.imgur.com/s9HSENw.jpg" alt="
The first sentence of the description is captured as the intro for the project and will be displayed on the mintbase landing page, use this to grab attention and get someone to click on your template.
Complete project description goes here. Explain the purpose, key features, or anything that provides context from both a business and technical perspective. This section should cover the 'what' and 'why' about the template, catering to users who may be deploying it for their business or developers looking to expand on it.
Complete project description goes here. Explain the purpose, key features, or anything that provides context from both a business and technical perspective. This section should cover the 'what' and 'why' about the template, catering to users who may be deploying it for their business or developers looking to expand on it.
[![Demo](https://img.shields.io/badge/Demo-Visit%20Demo-brightgreen)](https://your-live-app/)
Expand All @@ -102,7 +120,7 @@ Complete project description goes here. Explain the purpose, key features, or an
Explain the project structure, key components, or any significant details. Provide step-by-step instructions for running the project locally.
## Deployment
## Deployment
Deployment instructions. We include a link to deploy on vercel in every template because it makes it very easy for non developers to spin off their own tempaltes. This section is also a good place to speak about how to configure the project and environment variables.
Expand Down
2 changes: 1 addition & 1 deletion starter-vite/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<meta charset="UTF-8" />
<link rel="icon" type="image/svg+xml" href="/vite.svg" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Mintbase - Simple Login - Vite + React + TS</title>
<title>Bitte Templates - Simple Login - Vite + React + TS</title>
</head>
<body>
<div id="root"></div>
Expand Down
10 changes: 5 additions & 5 deletions starter-vite/package.json
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
{
"name": "Mintbase-Templates-Starter-Vite",
"name": "Bitte-Templates-Starter-Vite",
"keywords": [
"templates",
"mintbase",
"Bitte",
"web3",
"Vite",
"react",
"starter",
"nft"
],
"repository": "https://github.com/mintbase/templates.git",
"homepage": "https;//templates.mintbase.xyz/starter-vite",
"author": "Mintbase Team <eng@mintbase.xyz>",
"homepage": "https;//templates.bitte.ai/starter-vite",
"author": "Bitte Team <eng@bitte.ai>",
"private": true,
"version": "0.0.0",
"type": "module",
Expand All @@ -22,7 +22,7 @@
"preview": "vite preview"
},
"dependencies": {
"@mintbase-js/react": "0.6.4",
"@mintbase-js/react": "latest",
"buffer": "^6.0.3",
"react": "^18.2.0",
"react-dom": "^18.2.0",
Expand Down
10 changes: 5 additions & 5 deletions starter-vite/pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 5 additions & 5 deletions starter-vite/src/App.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { MintbaseWalletContextProvider } from "@mintbase-js/react";
import { BitteWalletContextProvider } from "@mintbase-js/react";
import "./App.css";
import { NearWalletConnector } from "./NearWalletConnector";
import "./shims";
Expand All @@ -7,7 +7,7 @@ import { SocialMedias } from "./Social";
import "@near-wallet-selector/modal-ui/styles.css";

function App() {
const MintbaseWalletSetup = {
const setup = {
contractAddress:
import.meta.env.VITE_CONTRACT_ADDRESS || "mintspace2.testnet",
network: import.meta.env.VITE_NETWORK || "testnet",
Expand All @@ -20,20 +20,20 @@ function App() {
<>
<SocialMedias />

<MintbaseWalletContextProvider {...MintbaseWalletSetup}>
<BitteWalletContextProvider {...setup}>
<main className="flex flex-col items-center justify-center mt-2 root">
<div className="mx-6 sm:mx-24 mt-4 mb-4">
<div className="w-full flex flex-col justify-center items-center">
<div className="w-full flex flex-col justify-center items-center space-y-8">
<div className="flex flex-col justify-center items-center space-y-8 text-[40px]">
Mintbase.js Simple Login Example
Bitte Wallet Simple Login Example
</div>
<NearWalletConnector />
</div>
</div>
</div>
</main>
</MintbaseWalletContextProvider>
</BitteWalletContextProvider>
</>
);
}
Expand Down
4 changes: 2 additions & 2 deletions starter-vite/src/NearWalletConnector.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { useMbWallet } from "@mintbase-js/react";
import { useBitteWallet } from "@mintbase-js/react";

export const NearWalletConnector = () => {
const { isConnected, selector, connect , activeAccountId } = useMbWallet();
const { isConnected, selector, connect , activeAccountId } = useBitteWallet();


const handleSignout = async () => {
Expand Down

0 comments on commit 8350a8f

Please sign in to comment.