{"id":13725453,"url":"https://github.com/fabe/gatsby-source-figma","last_synced_at":"2025-08-21T05:32:55.872Z","repository":{"id":57244945,"uuid":"126380353","full_name":"fabe/gatsby-source-figma","owner":"fabe","description":"🍭 Gatsby plugin for using Figma documents as a data source.","archived":false,"fork":false,"pushed_at":"2020-08-30T17:49:59.000Z","size":209,"stargazers_count":126,"open_issues_count":5,"forks_count":8,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-08-04T05:18:19.105Z","etag":null,"topics":["figma","figma-api","gatsby","gatsby-plugin","gatsby-source"],"latest_commit_sha":null,"homepage":"https://npm.im/gatsby-source-figma","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/fabe.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-03-22T18:42:38.000Z","updated_at":"2025-07-23T16:16:15.000Z","dependencies_parsed_at":"2022-09-01T06:12:01.748Z","dependency_job_id":null,"html_url":"https://github.com/fabe/gatsby-source-figma","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/fabe/gatsby-source-figma","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fabe%2Fgatsby-source-figma","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fabe%2Fgatsby-source-figma/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fabe%2Fgatsby-source-figma/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fabe%2Fgatsby-source-figma/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/fabe","download_url":"https://codeload.github.com/fabe/gatsby-source-figma/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fabe%2Fgatsby-source-figma/sbom","scorecard":{"id":389746,"data":{"date":"2025-08-11","repo":{"name":"github.com/fabe/gatsby-source-figma","commit":"b2489d2da4bf760b9341523896ed85f3d78fad6d"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3.3,"checks":[{"name":"Code-Review","score":2,"reason":"Found 3/15 approved changesets -- score normalized to 2","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: MIT License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 19 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}}]},"last_synced_at":"2025-08-18T17:31:39.727Z","repository_id":57244945,"created_at":"2025-08-18T17:31:39.727Z","updated_at":"2025-08-18T17:31:39.727Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":271430852,"owners_count":24758399,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-21T02:00:08.990Z","response_time":74,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["figma","figma-api","gatsby","gatsby-plugin","gatsby-source"],"created_at":"2024-08-03T01:02:23.910Z","updated_at":"2025-08-21T05:32:55.593Z","avatar_url":"https://github.com/fabe.png","language":"JavaScript","funding_links":[],"categories":["JavaScript"],"sub_categories":[],"readme":"# gatsby-source-figma\n\n[![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=flat-square)](http://makeapullrequest.com)\n[![npm](https://img.shields.io/npm/v/gatsby-source-figma.svg?style=flat-square)](https://npm.im/gatsby-source-figma)\n\nGatsby plugin for using [Figma](https://figma.com) documents as a data source.\n\n![Screenshot](.github/screenshot.jpg)\n\n## Installation\n\n    yarn add gatsby-source-figma\n\n## Usage\n\n```javascript\n// In your gatsby-config.js\n\nplugins: [\n  {\n    resolve: `gatsby-source-figma`,\n    options: {\n      // For files:\n      fileId: `FIGMA_FILE_ID`,\n      // For images:\n      nodeIds: [`FIGMA_NODE_IDS`],\n      // optional for nodeIds: A number between 0.01 and 4, the image scaling factor\n      scale: 1,\n      // optional: A string enum for the image output format, can be jpg, png, svg, or pdf\n      format: 'png'\n      // For projects:\n      projectId: `FIGMA_PROJECT_ID`,\n      // Get an access token from Figma Account Settings.\n      accessToken: `YOUR_FIGMA_ACCESS_TOKEN`,\n    },\n  },\n],\n```\n\nFor all requests, you must have an `accessToken`. You can create an access token inside your [Figma settings](https://www.figma.com/developers/docs#auth-dev-token).\n\nTo access a file, also pass a `fileId`.\n\nTo get screenshots, also pass in a `fileId`, `nodeIds`. Additionally, you can pass in `scale` (number) and/or `format` (png, jpg, svg, pdf), but they're not required.\n\nTo get a project, pass in a `projectId`.\n\n## Querying\n\n### Files\n\nMake sure that `fileId` and `accessToken` are set inside `gatsby-config.js`.\n\n```graphql\nquery StyleguideQuery {\n  figmaDocument {\n    name\n    lastModified\n    thumbnailUrl\n    pages {\n      name\n      children {\n        name\n      }\n    }\n  }\n}\n```\n\n### Images (Artboards, also known as nodes)\n\nMake sure that `fileId`, `nodeIds`, and `accessToken` are set inside `gatsby-config.js`. You can also set `scale` and `format`.\n\n\n`The node Id and file key can be parsed from any Figma node url:\n(https://www.figma.com/file/:key/:title?node-id=:id).`\n\n\n```graphql\nquery ImageQuery {\n  allFigmaImage {\n    nodes {\n      id\n      image\n    }\n  }\n}\n```\n\n### Projects\n\nMake sure that `projectId` and `accessToken` are set inside `gatsby-config.js`. Using this method, you can now query `components`, `frames`, `instances`, and more via `graphql` filters.\n\n```\n// All Figma Documents\n\nquery ProjectQuery {\n  allFigmaDocument {\n    edges {\n      node {\n        name\n        pages {\n          name\n        }\n      }\n    }\n  }\n}\n```\n\n```\n// Specific Figma Component\n\nquery ProjectComponentQuery {\n  figmaComponent(name: {eq: \"MyComponent\"}) {\n    instances {\n      name\n      rectangles {\n        name\n      }\n      texts {\n        name\n      }\n    }\n  }\n}\n```\n\n```\n// Figma Frames that start with \"Button\"\n\nquery ProjectFrameQuery {\n  allFigmaFrame(filter: {name: {regex: \"/Button/\"}}) {\n    edges {\n      node {\n        name\n      }\n    }\n  }\n}\n```\n\nUse the built-in GraphiQL tool (http://localhost:8000/___graphql) to get an idea of what you can query.\n\n## Todo\n\n* [x] Query `files`.\n* [ ] Query multiple `files`.\n* [x] Query one or multiple file `images`.\n* [x] Query `projects`.\n* [ ] Query file `comments`.\n\n## Authors\n\n* Fabian Schultz ([@fschultz\\_](https://twitter.com/fschultz_))\n* Emilie Martinez ([@emiliekmartinez](https://twitter.com/emiliekmartinez))\n* Brandon W. Kipp ([brandonwkipp](https://github.com/brandonwkipp))\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffabe%2Fgatsby-source-figma","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffabe%2Fgatsby-source-figma","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffabe%2Fgatsby-source-figma/lists"}