Skip to content

Add open-in-figma extension#27265

Closed
sasivarnan wants to merge 3 commits into
raycast:mainfrom
sasivarnan:ext/open-in-figma
Closed

Add open-in-figma extension#27265
sasivarnan wants to merge 3 commits into
raycast:mainfrom
sasivarnan:ext/open-in-figma

Conversation

@sasivarnan
Copy link
Copy Markdown
Contributor

@sasivarnan sasivarnan commented Apr 18, 2026

Description

Open in Figma - Open Figma URL in clipboard with Figma app

Screencast

Raycast 2026-04-18 at 12 34 00

Checklist

@raycastbot
Copy link
Copy Markdown
Collaborator

Congratulations on your new Raycast extension! 🚀

We're currently experiencing a high volume of incoming requests. As a result, the initial review may take up to 10-15 business days.

Once the PR is approved and merged, the extension will be available on our Store.

@sasivarnan sasivarnan marked this pull request as ready for review April 18, 2026 09:42
@greptile-apps
Copy link
Copy Markdown
Contributor

greptile-apps Bot commented Apr 18, 2026

Greptile Summary

This PR adds a new open-in-figma no-view extension that reads a URL from the clipboard and opens it in the Figma desktop app. The overall structure is clean and follows Raycast extension conventions, but there are two issues that should be addressed before merging:

  • The isFigmaInstalled helper returns true when Figma is not installed (the findIndex === -1 predicate is inverted relative to the function name). The call-site accidentally compensates for this, but a future maintainer relying on the name would introduce a real bug.
  • @raycast/utils is listed as a runtime dependency in package.json but is never imported in the source file.

Confidence Score: 4/5

Two P1 issues should be resolved before merging: the inverted isFigmaInstalled predicate and the unused @raycast/utils dependency.

The inverted boolean predicate creates a latent correctness risk (currently masked by the call-site), and the unused dependency violates the project's explicit rule. Both are straightforward to fix.

extensions/open-in-figma/src/open-in-figma.ts and extensions/open-in-figma/package.json

Important Files Changed

Filename Overview
extensions/open-in-figma/src/open-in-figma.ts Core command logic — contains an inverted isFigmaInstalled predicate that is accidentally correct at the call-site but would mislead any future caller
extensions/open-in-figma/package.json Extension manifest — @raycast/utils listed as a dependency but never imported in source
extensions/open-in-figma/.prettierrc Prettier config — correctly uses printWidth: 120 and singleQuote: false per project standard
extensions/open-in-figma/eslint.config.js ESLint config — correctly uses defineConfig from eslint/config with the Raycast preset
extensions/open-in-figma/CHANGELOG.md Changelog — uses {PR_MERGE_DATE} placeholder correctly for the initial release
extensions/open-in-figma/README.md README — minimal but accurate description of the extension's purpose
Prompt To Fix All With AI
This is a comment left during a code review.
Path: extensions/open-in-figma/src/open-in-figma.ts
Line: 14-17

Comment:
**Inverted function name — `isFigmaInstalled` returns `true` when Figma is absent**

The function is named `isFigmaInstalled` but `findIndex(...) === -1` evaluates to `true` only when no match is found (i.e. Figma is **not** installed). The call-site `if (await isFigmaInstalled())` then correctly shows the "not installed" HUD, so the end behaviour is accidentally correct — but the name is the opposite of what the implementation computes. A future maintainer changing `!isFigmaInstalled()` anywhere would introduce a real bug.

```suggestion
const isFigmaInstalled = async () => {
  const installedApps = await getApplications();
  return installedApps.some((app) => app.name === "Figma");
};
```

And update the call-site:

```typescript
if (!(await isFigmaInstalled())) {
```

How can I resolve this? If you propose a fix, please make it concise.

---

This is a comment left during a code review.
Path: extensions/open-in-figma/package.json
Line: 27-29

Comment:
**`@raycast/utils` declared as a dependency but never imported**

`@raycast/utils` appears in `dependencies` but is not imported anywhere in `src/open-in-figma.ts`. Unused dependencies bloat the bundle and installation time with no benefit.

```suggestion
  "dependencies": {
    "@raycast/api": "^1.104.12"
  },
```

**Rule Used:** What: Every dependency listed in package.json must... ([source](https://app.greptile.com/review/custom-context?memory=bffc60eb-f9f2-4219-b804-76e29e267d43))

How can I resolve this? If you propose a fix, please make it concise.

Reviews (1): Last reviewed commit: "Added check to find if Figma is installe..." | Re-trigger Greptile

Comment thread extensions/open-in-figma/src/open-in-figma.ts
Comment thread extensions/open-in-figma/package.json Outdated
@raycastbot
Copy link
Copy Markdown
Collaborator

This pull request has been automatically marked as stale because it did not have any recent activity.

It will be closed if no further activity occurs in the next 7 days to keep our backlog clean 😊

@raycastbot raycastbot added the status: stalled Stalled due inactivity label May 2, 2026
@raycastbot
Copy link
Copy Markdown
Collaborator

This pull request has been automatically closed due to inactivity.

Feel free to comment in the thread when you're ready to continue working on it 🙂

You can also catch us in Slack if you want to discuss this.

@raycastbot raycastbot closed this May 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

new extension Label for PRs with new extensions platform: macOS platform: Windows status: stalled Stalled due inactivity

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants