-
Notifications
You must be signed in to change notification settings - Fork 0
feat: embeddable + deps migration #22
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
petar-omni
wants to merge
4
commits into
main
Choose a base branch
from
feat/misc
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,31 +1,43 @@ | ||
| name: Continuous Integration | ||
| name: CI | ||
|
|
||
| on: | ||
| pull_request: | ||
| types: | ||
| - opened | ||
| - reopened | ||
| - synchronize | ||
|
|
||
| permissions: | ||
| contents: read | ||
|
|
||
| concurrency: | ||
| group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} | ||
| group: ci-${{ github.workflow }}-${{ github.event.pull_request.number }} | ||
| cancel-in-progress: true | ||
|
|
||
| jobs: | ||
| check: | ||
| checks: | ||
| name: Lint, build and test | ||
| runs-on: ubuntu-latest | ||
|
|
||
| steps: | ||
| - uses: actions/checkout@v4 | ||
| - name: Checkout | ||
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | ||
|
|
||
| - uses: jdx/mise-action@v2 | ||
| - name: Install mise | ||
| run: | | ||
| curl https://mise.run | MISE_VERSION=v2026.5.6 sh | ||
| echo "$HOME/.local/bin" >> "$GITHUB_PATH" | ||
| echo "$HOME/.local/share/mise/shims" >> "$GITHUB_PATH" | ||
| export PATH="$HOME/.local/bin:$HOME/.local/share/mise/shims:$PATH" | ||
| mise install | ||
|
|
||
| - run: pnpm install --frozen-lockfile | ||
| - name: Install dependencies | ||
| run: pnpm install --frozen-lockfile | ||
|
|
||
| - name: Install Playwright Browsers | ||
| run: pnpm exec playwright install --with-deps | ||
|
|
||
| - run: pnpm run lint | ||
| - name: Lint | ||
| run: pnpm lint | ||
|
|
||
| - run: pnpm run build | ||
| - name: Build | ||
| run: pnpm build | ||
|
|
||
| - run: pnpm run test | ||
| - name: Test | ||
| run: pnpm test |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -12,4 +12,5 @@ dist-ssr | |
| opensrc/ | ||
|
|
||
| .turbo | ||
| *.tsbuildinfo | ||
| *.tsbuildinfo | ||
| .pnpm-store/ | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,3 @@ | ||
| [submodule ".external/effect-smol"] | ||
| path = .external/effect-smol | ||
| url = https://github.com/Effect-TS/effect-smol.git |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,25 @@ | ||
| # AGENTS.md | ||
|
|
||
| Instructions for AI coding agents working with this codebase. | ||
|
|
||
| ## Commands | ||
|
|
||
| After each code change, run these commands to confirm that nothing is broken | ||
|
|
||
| - To lint and typecheck, run: `pnpm turbo lint --filter=@yieldxyz/perps-{package}`, | ||
| - For code formatting, run: `pnpm turbo format --filter=@yieldxyz/perps-{package}`, | ||
| - If a file is added, removed, or changed in `routes` folder, to generate route tree run: `pnpm turbo generate-routes --filter=@yieldxyz/perps-{package}` | ||
|
|
||
| ## General rules | ||
|
|
||
| - Don't mix components/UI and logic - separate those two in hooks and components files | ||
| - All state handling should be done with `@effect-atom/atom-react` | ||
| - Use `effect` as much as possible. Don't use async/await | ||
| - Math/finance calculations and functions are placed in `packages/common/src/lib/math.ts` | ||
| - For manipulating array and records use `effect/Array` and `effect/Record` | ||
| - Don't use hooks `useMemo` or `useCallback` as we're using react-compiler | ||
| - During refactoring, avoid re-exporting functionality. Update imports in file thats importing this functionality | ||
|
|
||
| ## Source code references | ||
|
|
||
| - Check `.external/effect-smol` for all references related to effect. Do not look up web for docs. They are not available yet as this is beta version |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,4 @@ | ||
| VITE_PERPS_BASE_URL= | ||
| VITE_PERPS_API_KEY= | ||
| VITE_REOWN_PROJECT_ID= | ||
| VITE_MORALIS_API_KEY= |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,12 @@ | ||
| <!doctype html> | ||
| <html lang="en"> | ||
| <head> | ||
| <meta charset="UTF-8" /> | ||
| <meta name="viewport" content="width=device-width, initial-scale=1.0" /> | ||
| <title>Perps Dashboard React Example</title> | ||
| </head> | ||
| <body> | ||
| <div id="root"></div> | ||
| <script type="module" src="/src/main.tsx"></script> | ||
| </body> | ||
| </html> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,22 @@ | ||
| { | ||
| "name": "@yieldxyz/perps-dashboard-react-example", | ||
| "private": true, | ||
| "type": "module", | ||
| "scripts": { | ||
| "dev": "vite --port 3102", | ||
| "build": "vite build", | ||
| "preview": "vite preview" | ||
| }, | ||
| "dependencies": { | ||
| "@yieldxyz/perps-dashboard": "workspace:*", | ||
| "react": "catalog:", | ||
| "react-dom": "catalog:" | ||
| }, | ||
| "devDependencies": { | ||
| "@types/react": "catalog:", | ||
| "@types/react-dom": "catalog:", | ||
| "@vitejs/plugin-react": "catalog:", | ||
| "typescript": "catalog:", | ||
| "vite": "catalog:" | ||
| } | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,19 @@ | ||
| import { Dashboard, type PerpsConfig } from "@yieldxyz/perps-dashboard"; | ||
| import "@yieldxyz/perps-dashboard/styles.css"; | ||
| import { createRoot } from "react-dom/client"; | ||
| import "./styles.css"; | ||
|
|
||
| const config: PerpsConfig = { | ||
| perpsBaseUrl: import.meta.env.VITE_PERPS_BASE_URL, | ||
| perpsApiKey: import.meta.env.VITE_PERPS_API_KEY, | ||
| reownProjectId: import.meta.env.VITE_REOWN_PROJECT_ID || undefined, | ||
| moralisApiKey: import.meta.env.VITE_MORALIS_API_KEY, | ||
| }; | ||
|
|
||
| const rootElement = document.getElementById("root"); | ||
|
|
||
| if (!rootElement) { | ||
| throw new Error("Root element not found"); | ||
| } | ||
|
|
||
| createRoot(rootElement).render(<Dashboard config={config} />); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,14 @@ | ||
| html { | ||
| background: #121314; | ||
| } | ||
|
|
||
| body { | ||
| margin: 0; | ||
| min-width: 320px; | ||
| background: #121314; | ||
| } | ||
|
|
||
| #root { | ||
| min-height: 100vh; | ||
| background: #121314; | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,7 @@ | ||
| { | ||
| "extends": "../../tsconfig.base.json", | ||
| "compilerOptions": { | ||
| "noEmit": true | ||
| }, | ||
| "include": ["src", "vite.config.ts"] | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,6 @@ | ||
| import react from "@vitejs/plugin-react"; | ||
| import { defineConfig } from "vite"; | ||
|
|
||
| export default defineConfig({ | ||
| plugins: [react()], | ||
| }); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,4 @@ | ||
| VITE_PERPS_BASE_URL= | ||
| VITE_PERPS_API_KEY= | ||
| VITE_REOWN_PROJECT_ID= | ||
| VITE_MORALIS_API_KEY= |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,12 @@ | ||
| <!doctype html> | ||
| <html lang="en"> | ||
| <head> | ||
| <meta charset="UTF-8" /> | ||
| <meta name="viewport" content="width=device-width, initial-scale=1.0" /> | ||
| <title>Perps Dashboard Vanilla Example</title> | ||
| </head> | ||
| <body> | ||
| <div id="app"></div> | ||
| <script type="module" src="/src/main.js"></script> | ||
| </body> | ||
| </html> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,16 @@ | ||
| { | ||
| "name": "@yieldxyz/perps-dashboard-vanilla-example", | ||
| "private": true, | ||
| "type": "module", | ||
| "scripts": { | ||
| "dev": "vite --port 3103", | ||
| "build": "vite build", | ||
| "preview": "vite preview" | ||
| }, | ||
| "dependencies": { | ||
| "@yieldxyz/perps-dashboard": "workspace:*" | ||
| }, | ||
| "devDependencies": { | ||
| "vite": "catalog:" | ||
| } | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,16 @@ | ||
| import { mountDashboard } from "@yieldxyz/perps-dashboard/vanilla"; | ||
| import "@yieldxyz/perps-dashboard/styles.css"; | ||
| import "./styles.css"; | ||
|
|
||
| const config = { | ||
| perpsBaseUrl: import.meta.env.VITE_PERPS_BASE_URL, | ||
| perpsApiKey: import.meta.env.VITE_PERPS_API_KEY, | ||
| reownProjectId: import.meta.env.VITE_REOWN_PROJECT_ID || undefined, | ||
| moralisApiKey: import.meta.env.VITE_MORALIS_API_KEY, | ||
| }; | ||
|
|
||
| const dashboard = mountDashboard("#app", { config }); | ||
|
|
||
| if (import.meta.hot) { | ||
| import.meta.hot.dispose(() => dashboard.unmount()); | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,14 @@ | ||
| html { | ||
| background: #121314; | ||
| } | ||
|
|
||
| body { | ||
| margin: 0; | ||
| min-width: 320px; | ||
| background: #121314; | ||
| } | ||
|
|
||
| #app { | ||
| min-height: 100vh; | ||
| background: #121314; | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,3 @@ | ||
| import { defineConfig } from "vite"; | ||
|
|
||
| export default defineConfig({}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,4 @@ | ||
| VITE_PERPS_BASE_URL= | ||
| VITE_PERPS_API_KEY= | ||
| VITE_REOWN_PROJECT_ID= | ||
| VITE_MORALIS_API_KEY= |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,12 @@ | ||
| <!doctype html> | ||
| <html lang="en"> | ||
| <head> | ||
| <meta charset="UTF-8" /> | ||
| <meta name="viewport" content="width=device-width, initial-scale=1.0" /> | ||
| <title>Perps Widget React Example</title> | ||
| </head> | ||
| <body> | ||
| <div id="root"></div> | ||
| <script type="module" src="/src/main.tsx"></script> | ||
| </body> | ||
| </html> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,22 @@ | ||
| { | ||
| "name": "@yieldxyz/perps-widget-react-example", | ||
| "private": true, | ||
| "type": "module", | ||
| "scripts": { | ||
| "dev": "vite --port 3100", | ||
| "build": "vite build", | ||
| "preview": "vite preview" | ||
| }, | ||
| "dependencies": { | ||
| "@yieldxyz/perps-widget": "workspace:*", | ||
| "react": "catalog:", | ||
| "react-dom": "catalog:" | ||
| }, | ||
| "devDependencies": { | ||
| "@types/react": "catalog:", | ||
| "@types/react-dom": "catalog:", | ||
| "@vitejs/plugin-react": "catalog:", | ||
| "typescript": "catalog:", | ||
| "vite": "catalog:" | ||
| } | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,20 @@ | ||
| import { type PerpsConfig, Widget } from "@yieldxyz/perps-widget"; | ||
| import "@yieldxyz/perps-widget/styles.css"; | ||
| import { createRoot } from "react-dom/client"; | ||
| import "./styles.css"; | ||
|
|
||
| const config: PerpsConfig = { | ||
| perpsBaseUrl: "https://perps.yield.xyz", | ||
| perpsApiKey: "e2d627cf-2ae3-4775-9fbc-76819c7cae38", | ||
| reownProjectId: "29e1b718ad16983a0705cf24d5b5b747", | ||
| moralisApiKey: | ||
| "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJub25jZSI6IjhlNTk0NDE0LTg3NGMtNDZlMC1iMWNlLWU5ZjYzMjY1YWExMiIsIm9yZ0lkIjoiNDI2Nzk1IiwidXNlcklkIjoiNDM4OTk2IiwidHlwZSI6IlBST0pFQ1QiLCJ0eXBlSWQiOiI2YzMwMDY3Yi1kNDEyLTQwYjYtYTQ4OS0zYjEwM2ExNThjOGMiLCJpYXQiOjE3Mzc0NTA4NzcsImV4cCI6NDg5MzIxMDg3N30.pd8sKdRHdtlqoZVS7wb8Jyy2GLhhr95X8yW64W_gSC0", | ||
| }; | ||
|
|
||
| const rootElement = document.getElementById("root"); | ||
|
|
||
| if (!rootElement) { | ||
| throw new Error("Root element not found"); | ||
| } | ||
|
|
||
| createRoot(rootElement).render(<Widget config={config} />); | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,24 @@ | ||
| html { | ||
| background: #131517; | ||
| } | ||
|
|
||
| body { | ||
| margin: 0; | ||
| min-width: 320px; | ||
| background: #131517; | ||
| } | ||
|
|
||
| #root { | ||
| min-height: 100vh; | ||
| display: flex; | ||
| justify-content: center; | ||
| align-items: flex-start; | ||
| padding: 30px 16px; | ||
| box-sizing: border-box; | ||
| } | ||
|
|
||
| @media (min-width: 768px) { | ||
| #root { | ||
| padding: 32px; | ||
| } | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,7 @@ | ||
| { | ||
| "extends": "../../tsconfig.base.json", | ||
| "compilerOptions": { | ||
| "noEmit": true | ||
| }, | ||
| "include": ["src", "vite.config.ts"] | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,6 @@ | ||
| import react from "@vitejs/plugin-react"; | ||
| import { defineConfig } from "vite"; | ||
|
|
||
| export default defineConfig({ | ||
| plugins: [react()], | ||
| }); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,4 @@ | ||
| VITE_PERPS_BASE_URL= | ||
| VITE_PERPS_API_KEY= | ||
| VITE_REOWN_PROJECT_ID= | ||
| VITE_MORALIS_API_KEY= |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,12 @@ | ||
| <!doctype html> | ||
| <html lang="en"> | ||
| <head> | ||
| <meta charset="UTF-8" /> | ||
| <meta name="viewport" content="width=device-width, initial-scale=1.0" /> | ||
| <title>Perps Widget Vanilla Example</title> | ||
| </head> | ||
| <body> | ||
| <div id="app"></div> | ||
| <script type="module" src="/src/main.js"></script> | ||
| </body> | ||
| </html> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,16 @@ | ||
| { | ||
| "name": "@yieldxyz/perps-widget-vanilla-example", | ||
| "private": true, | ||
| "type": "module", | ||
| "scripts": { | ||
| "dev": "vite --port 3101", | ||
| "build": "vite build", | ||
| "preview": "vite preview" | ||
| }, | ||
| "dependencies": { | ||
| "@yieldxyz/perps-widget": "workspace:*" | ||
| }, | ||
| "devDependencies": { | ||
| "vite": "catalog:" | ||
| } | ||
| } |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove hardcoded credentials from client code.
Line 8 and Line 11 embed live-looking secrets directly in the frontend bundle. That is a credential leak risk; move them to
import.meta.envand rotate the exposed keys/tokens.Suggested fix
const config: PerpsConfig = { perpsBaseUrl: "https://perps.yield.xyz", - perpsApiKey: "e2d627cf-2ae3-4775-9fbc-76819c7cae38", - reownProjectId: "29e1b718ad16983a0705cf24d5b5b747", - moralisApiKey: - "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJub25jZSI6IjhlNTk0NDE0LTg3NGMtNDZlMC1iMWNlLWU5ZjYzMjY1YWExMiIsIm9yZ0lkIjoiNDI2Nzk1IiwidXNlcklkIjoiNDM4OTk2IiwidHlwZSI6IlBST0pFQ1QiLCJ0eXBlSWQiOiI2YzMwMDY3Yi1kNDEyLTQwYjYtYTQ4OS0zYjEwM2ExNThjOGMiLCJpYXQiOjE3Mzc0NTA4NzcsImV4cCI6NDg5MzIxMDg3N30.pd8sKdRHdtlqoZVS7wb8Jyy2GLhhr95X8yW64W_gSC0", + perpsApiKey: import.meta.env.VITE_PERPS_API_KEY, + reownProjectId: import.meta.env.VITE_REOWN_PROJECT_ID, + moralisApiKey: import.meta.env.VITE_MORALIS_API_KEY, };📝 Committable suggestion
🧰 Tools
🪛 Betterleaks (1.2.0)
[high] 8-8: Detected a Generic API Key, potentially exposing access to various services and sensitive operations.
(generic-api-key)
[high] 11-11: Uncovered a JSON Web Token, which may lead to unauthorized access to web applications and sensitive user data.
(jwt)
🤖 Prompt for AI Agents